var JSX = {}; (function () { /** * copies the implementations from source interface to target */ function $__jsx_merge_interface(target, source) { for (var k in source.prototype) if (source.prototype.hasOwnProperty(k)) target.prototype[k] = source.prototype[k]; } /** * defers the initialization of the property */ function $__jsx_lazy_init(obj, prop, func) { function reset(obj, prop, value) { delete obj[prop]; obj[prop] = value; return value; } Object.defineProperty(obj, prop, { get: function () { return reset(obj, prop, func()); }, set: function (v) { reset(obj, prop, v); }, enumerable: true, configurable: true }); } /* * global functions called by JSX as Number.* (renamed so that they do not conflict with local variable names) */ var $__jsx_parseInt = parseInt; var $__jsx_parseFloat = parseFloat; var $__jsx_isNaN = isNaN; var $__jsx_isFinite = isFinite; var $__jsx_ObjectToString = Object.prototype.toString; var $__jsx_ObjectHasOwnProperty = Object.prototype.hasOwnProperty; /* * public interface to JSX code */ JSX.require = function (path) { var m = $__jsx_classMap[path]; return m !== undefined ? m : null; } /** * class Application extends Object * @constructor */ function Application() { } Application.prototype = new Object; /** * @constructor */ function Application$() { }; Application$.prototype = new Application; /** * @param {!string} elm_id */ Application.main$S = function (elm_id) { /** @type {HTMLElement} */ var elm; var f; elm = (function (o) { return o instanceof HTMLElement ? o : null; })(dom.window.document.getElementById(elm_id)); f = (function () { /** @type {Date} */ var date; /** @type {!string} */ var delimiter; /** @type {!string} */ var hour; /** @type {!string} */ var min; /** @type {!string} */ var sec; date = new Date(); delimiter = ":"; hour = date.getHours() + ""; min = date.getMinutes() + ""; sec = date.getSeconds() + ""; elm.innerHTML = hour + delimiter + min + delimiter + sec; }); Timer$setInterval$F$V$I(f, 100); }; var Application$main$S = Application.main$S; /** * class TimerHandle extends Object * @constructor */ function TimerHandle() { } TimerHandle.prototype = new Object; /** * @constructor */ function TimerHandle$() { }; TimerHandle$.prototype = new TimerHandle; /** * class Timer extends Object * @constructor */ function Timer() { } Timer.prototype = new Object; /** * @constructor */ function Timer$() { }; Timer$.prototype = new Timer; /** * @param {!number} milliseconds * @return {TimerHandle} */ Timer.setTimeout$F$V$I = function (listener, milliseconds) { var f; f = (function (o) { return typeof(o) === "function" ? o : null; })(js.global.setTimeout); return f(listener, milliseconds); }; var Timer$setTimeout$F$V$I = Timer.setTimeout$F$V$I; /** * @param {TimerHandle} timerID */ Timer.clearTimeout$LTimerHandle$ = function (timerID) { var f; f = (function (o) { return typeof(o) === "function" ? o : null; })(js.global.clearTimeout); f(timerID); }; var Timer$clearTimeout$LTimerHandle$ = Timer.clearTimeout$LTimerHandle$; /** * @param {!number} milliseconds * @return {TimerHandle} */ Timer.setInterval$F$V$I = function (listener, milliseconds) { var f; f = (function (o) { return typeof(o) === "function" ? o : null; })(js.global.setInterval); return f(listener, milliseconds); }; var Timer$setInterval$F$V$I = Timer.setInterval$F$V$I; /** * @param {TimerHandle} timerID */ Timer.clearInterval$LTimerHandle$ = function (timerID) { var f; f = (function (o) { return typeof(o) === "function" ? o : null; })(js.global.clearInterval); f(timerID); }; var Timer$clearInterval$LTimerHandle$ = Timer.clearInterval$LTimerHandle$; /** * class dom extends Object * @constructor */ function dom() { } dom.prototype = new Object; /** * @constructor */ function dom$() { }; dom$.prototype = new dom; /** * @param {!string} id * @return {HTMLElement} */ dom.id$S = function (id) { return (function (o) { return o instanceof HTMLElement ? o : null; })(dom.window.document.getElementById(id)); }; var dom$id$S = dom.id$S; /** * @param {!string} id * @return {HTMLElement} */ dom.getElementById$S = function (id) { return (function (o) { return o instanceof HTMLElement ? o : null; })(dom.window.document.getElementById(id)); }; var dom$getElementById$S = dom.getElementById$S; /** * @param {!string} tag * @return {HTMLElement} */ dom.createElement$S = function (tag) { return dom.window.document.createElement(tag); }; var dom$createElement$S = dom.createElement$S; /** * class js extends Object * @constructor */ function js() { } js.prototype = new Object; /** * @constructor */ function js$() { }; js$.prototype = new js; $__jsx_lazy_init(dom, "window", function () { return js.global.window; }); js.global = (function () { return this; })(); var $__jsx_classMap = { "digital_watch.jsx": { Application: Application, Application$: Application$ }, "system:lib/js/timer.jsx": { TimerHandle: TimerHandle, TimerHandle$: TimerHandle$, Timer: Timer, Timer$: Timer$ }, "system:lib/js/js/web.jsx": { dom: dom, dom$: dom$ }, "system:lib/js/js.jsx": { js: js, js$: js$ } }; }()); var dw = JSX;