Author: damoxc
Revision: 5688
Log:
add the session timeout to one of the options on the interface
preferences
Diff:
Modified: trunk/deluge/ui/web/js/Deluge.Preferences.Interface.js
===================================================================
--- trunk/deluge/ui/web/js/Deluge.Preferences.Interface.js 2009-08-20
00:31:31 UTC (rev 5687)
+++ trunk/deluge/ui/web/js/Deluge.Preferences.Interface.js 2009-08-20
00:32:32 UTC (rev 5688)
@@ -94,10 +94,32 @@
}
}
});
+
+ fieldset = this.add({
+ xtype: 'fieldset',
+ border: false,
+ title: _('Session'),
+ autoHeight: true,
+ labelWidth: 110,
+ defaultType: 'uxspinner',
+ defaults: {
+ width: 80,
+ }
+ });
+ optMan.bind('session_timeout', fieldset.add({
+ name: 'session_timeout',
+ fieldLabel: _('Session Timeout')
+ }));
},
onApply: function() {
- alert('apply');
+ var changed = this.optionsManager.getDirty();
+ if (!Ext.isObjectEmpty(changed)) {
+ Deluge.Client.web.set_config(changed, {
+ success: this.onSetConfig,
+ scope: this
+ });
+ }
},
onGotConfig: function(config) {
@@ -149,6 +171,10 @@
});
},
+ onSetConfig: function() {
+ this.getOptionsManager().commit();
+ },
+
onShow: function() {
Ext.deluge.preferences.Interface.superclass.onShow.call(this);
Deluge.Client.web.get_config({
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"deluge-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/deluge-commit?hl=en
-~----------~----~----~----~------~----~------~--~---