From: Darren Date: Thu, 16 May 2013 14:28:55 +0000 (+0100) Subject: Client: Added app.panels() to global object X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=a9bc007fbde5d284ebfac235a9d5a4c7bca63dfe;p=KiwiIRC.git Client: Added app.panels() to global object --- diff --git a/client/assets/dev/model_application.js b/client/assets/dev/model_application.js index 2404628..0fe66b1 100644 --- a/client/assets/dev/model_application.js +++ b/client/assets/dev/model_application.js @@ -132,7 +132,10 @@ _kiwi.model.Application = function () { this.initializeGlobals = function () { _kiwi.global.connections = this.connections; - + + _kiwi.global.panels = this.panels; + _kiwi.global.panels.applets = this.applet_panels; + _kiwi.global.components.Applet = _kiwi.model.Applet; _kiwi.global.components.Panel =_kiwi.model.Panel; }; @@ -305,7 +308,9 @@ _kiwi.model.Application = function () { // Active panels / server panels.active = this.connections.active_panel; - panels.server = this.connections.active_connection.panels.server; + panels.server = this.connections.active_connection ? + this.connections.active_connection.panels.server : + null; return panels; };