diff --git a/deluge/ui/webui/templates/ajax/render/html/preferences_network.html b/deluge/ui/webui/templates/ajax/render/html/preferences_network.html index a6b86047b..9777c61a6 100644 --- a/deluge/ui/webui/templates/ajax/render/html/preferences_network.html +++ b/deluge/ui/webui/templates/ajax/render/html/preferences_network.html @@ -1,7 +1,7 @@
$_('Ports') -
+
diff --git a/deluge/ui/webui/templates/ajax/static/js/deluge.widgets.js b/deluge/ui/webui/templates/ajax/static/js/deluge.widgets.js index 7ff8c85a5..2f061e44f 100644 --- a/deluge/ui/webui/templates/ajax/static/js/deluge.widgets.js +++ b/deluge/ui/webui/templates/ajax/static/js/deluge.widgets.js @@ -925,10 +925,18 @@ Deluge.Widgets.PreferencesWindow = new Class({ shown: function(event) { // we want this to be blocking var config = Deluge.Client.get_config({async: false}); + + // Unfortunately we have to modify the listen ports preferences + // in order to not have to modify the generic preferences class. + config['start_listen_port'] = config['listen_ports'][0]; + config['end_listen_port'] = config['listen_ports'][1]; + + // Iterate through the pages and set the fields this.categories.each(function(category) { if (category.update && category.core) category.update(config); }); + // Update the config for the webui pages. var webconfig = Deluge.Client.get_webui_config({async: false}); this.webui.update(webconfig); }