mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-03 06:58:42 +00:00
move the stateful stuff to Deluge.js before any other js has executed
This commit is contained in:
parent
d075ac888e
commit
3f8abf1e34
2 changed files with 171 additions and 170 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
Script: deluge-ui.js
|
||||
Script: Deluge.UI.js
|
||||
The core ui module that builds up the ui layout and controls the polling
|
||||
of the server.
|
||||
|
||||
|
@ -40,8 +40,6 @@ Copyright:
|
|||
*/
|
||||
Deluge.UI = {
|
||||
|
||||
cookies: new Ext.state.CookieProvider(),
|
||||
|
||||
errorCount: 0,
|
||||
|
||||
/**
|
||||
|
@ -49,7 +47,6 @@ Deluge.UI = {
|
|||
* and set up various events that the UI will utilise.
|
||||
*/
|
||||
initialize: function() {
|
||||
Ext.state.Manager.setProvider(this.cookies);
|
||||
this.MainPanel = new Ext.Panel({
|
||||
id: 'mainPanel',
|
||||
iconCls: 'x-deluge-main-panel',
|
||||
|
@ -182,7 +179,7 @@ Deluge.UI = {
|
|||
|
||||
// Enable the plugin
|
||||
Deluge.Plugins[options.pluginName].enable();
|
||||
},
|
||||
},
|
||||
|
||||
/**
|
||||
* @static
|
||||
|
|
|
@ -31,8 +31,12 @@ Copyright:
|
|||
statement from all source files in the program, then also delete it here.
|
||||
*/
|
||||
|
||||
// Create the namespace Ext.deluge
|
||||
Ext.namespace('Ext.deluge');
|
||||
|
||||
// Setup the state manager
|
||||
Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
|
||||
|
||||
(function() {
|
||||
/* Add some helper functions to Ext */
|
||||
Ext.apply(Function.prototype, {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue