diff --git a/modules/ClockFace.js b/modules/ClockFace.js index 9939ae4fa..d6c3a2e66 100644 --- a/modules/ClockFace.js +++ b/modules/ClockFace.js @@ -66,7 +66,10 @@ ClockFace.prototype.tick = function() { }; ClockFace.prototype.start = function() { - Bangle.CLOCK = 1; + /* Some widgets want to know if we're in a clock or not (like chrono, widget clock, etc). Normally + .CLOCK is set by Bangle.setUI('clock') but we want to load widgets so we can check appRect and *then* + call setUI. see #1864 */ + Bangle.CLOCK = 1; Bangle.loadWidgets(); if (this.init) this.init.apply(this); if (this._upDown) Bangle.setUI("clockupdown", d=>this._upDown.apply(this,[d])); @@ -104,4 +107,4 @@ ClockFace.prototype.redraw = function() { this.tick(); }; -exports = ClockFace; \ No newline at end of file +exports = ClockFace;