Merge branch 'develop' of /var/lib/git/repositories/manuel/uhr

This commit is contained in:
Manuel Friedli 2013-12-17 21:51:20 +01:00
commit 93b8a35840
2 changed files with 7 additions and 5 deletions

View File

@ -27,18 +27,21 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<link rel="stylesheet" type="text/css" href="uhr-white.css" /> <link rel="stylesheet" type="text/css" href="uhr-white.css" />
<meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
</head> </head>
<body> <body style="padding:0;margin:0;">
<div id="uhr"></div> <div id="uhr"></div>
<p id="disclaimer">Created by fritteli, inspired by <a href="http://www.qlocktwo.com/">QLOCKTWO</a>. <p id="disclaimer">Created by fritteli, inspired by <a href="http://www.qlocktwo.com/">QLOCKTWO</a>.
<script type="text/javascript" src="uhr-de_CH.js"></script> <script type="text/javascript" src="uhr-de_CH.js"></script>
<script type="text/javascript" src="uhr-de.js"></script> <script type="text/javascript" src="uhr-de.js"></script>
<script type="text/javascript" src="uhr-en.js"></script> <script type="text/javascript" src="uhr-en.js"></script>
<script type="text/javascript"> <script type="text/javascript">
var height = jQuery(window).height();
var width = jQuery(window).width();
var size = height < width ? height : width;
new Uhr(jQuery('#uhr'), { new Uhr(jQuery('#uhr'), {
layout: 'de_CH', layout: 'de_CH',
theme: 'black', theme: 'black',
status: 'on', status: 'on',
width: '20em' width: size + 'px'
}); });
</script> </script>
</body> </body>

5
uhr.js
View File

@ -17,7 +17,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
* @param clockarea Das jQuery-gewrappte HTML-Element, auf dem die Uhr angezeigt werden soll. * @param clockarea Das jQuery-gewrappte HTML-Element, auf dem die Uhr angezeigt werden soll.
* @param themeElement Das HTML-Stylesheet-Tag, das das Theme-CSS referenziert. * @param themeElement Das HTML-Stylesheet-Tag, das das Theme-CSS referenziert.
*/ */
if (typeof Uhr === 'undefined') { //if (typeof Uhr === 'undefined') {
function Uhr(clockarea, settings) { function Uhr(clockarea, settings) {
this.id = Uhr.id++; this.id = Uhr.id++;
this.timer = null; this.timer = null;
@ -340,5 +340,4 @@ function m(letter) {
} }
return l(letter, style); return l(letter, style);
} }
} //}