summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCalum Lind <calumlind+deluge@gmail.com>2013-05-11 16:15:17 +0100
committerCalum Lind <calumlind+deluge@gmail.com>2013-05-12 00:15:15 +0100
commit7bd53903a425ec5d00b79d93d1d0edcdab779ee2 (patch)
tree5b46853f84583bf4e036378e59a20a970d9109ed
parent8d63ce3ce524d141771dd850dd7217d0b73be13e (diff)
downloaddeluge-7bd53903a425ec.zip
deluge-7bd53903a425ec.tar.gz
deluge-7bd53903a425ec.tar.bz2
Rearrange the Network tab in GTK and Web UIs
Also applied the suggestions in #2055 including removing 'Encrypt Entire Stream' and default it (prefer_rc4) to True
-rw-r--r--deluge/core/preferencesmanager.py7
-rw-r--r--deluge/ui/console/modes/preference_panes.py1
-rw-r--r--deluge/ui/gtkui/glade/preferences_dialog.ui912
-rw-r--r--deluge/ui/gtkui/preferences.py16
-rw-r--r--deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js22
-rw-r--r--deluge/ui/web/js/deluge-all/preferences/NetworkPage.js75
6 files changed, 475 insertions, 558 deletions
diff --git a/deluge/core/preferencesmanager.py b/deluge/core/preferencesmanager.py
index 68c7d7f..f22c6b2 100644
--- a/deluge/core/preferencesmanager.py
+++ b/deluge/core/preferencesmanager.py
@@ -73,7 +73,6 @@ DEFAULT_PREFS = {
"enc_in_policy": 1,
"enc_out_policy": 1,
"enc_level": 2,
- "enc_prefer_rc4": True,
"max_connections_global": 200,
"max_upload_speed": -1.0,
"max_download_speed": -1.0,
@@ -305,18 +304,16 @@ class PreferencesManager(component.Component):
def _on_set_enc_level(self, key, value):
self._on_set_encryption(key, value)
- def _on_set_enc_prefer_rc4(self, key, value):
- self._on_set_encryption(key, value)
-
def _on_set_encryption(self, key, value):
log.debug("encryption value %s set to %s..", key, value)
pe_enc_level = {0: lt.enc_level.plaintext, 1: lt.enc_level.rc4, 2: lt.enc_level.both}
+
pe_settings = lt.pe_settings()
pe_settings.out_enc_policy = \
lt.enc_policy(self.config["enc_out_policy"])
pe_settings.in_enc_policy = lt.enc_policy(self.config["enc_in_policy"])
pe_settings.allowed_enc_level = lt.enc_level(pe_enc_level[self.config["enc_level"]])
- pe_settings.prefer_rc4 = self.config["enc_prefer_rc4"]
+ pe_settings.prefer_rc4 = True
self.session.set_pe_settings(pe_settings)
set = self.session.get_pe_settings()
log.debug("encryption settings:\n\t\t\tout_policy: %s\n\t\t\
diff --git a/deluge/ui/console/modes/preference_panes.py b/deluge/ui/console/modes/preference_panes.py
index da042bc..78c4efd 100644
--- a/deluge/ui/console/modes/preference_panes.py
+++ b/deluge/ui/console/modes/preference_panes.py
@@ -287,7 +287,6 @@ class NetworkPane(BasePane):
self.add_select_input("enc_in_policy","Inbound:",["Forced","Enabled","Disabled"],[0,1,2],parent.core_config["enc_in_policy"])
self.add_select_input("enc_out_policy","Outbound:",["Forced","Enabled","Disabled"],[0,1,2],parent.core_config["enc_out_policy"])
self.add_select_input("enc_level","Level:",["Handshake","Full Stream","Either"],[0,1,2],parent.core_config["enc_level"])
- self.add_checked_input("enc_prefer_rc4","Encrypt Entire Stream",parent.core_config["enc_prefer_rc4"])
class BandwidthPane(BasePane):
diff --git a/deluge/ui/gtkui/glade/preferences_dialog.ui b/deluge/ui/gtkui/glade/preferences_dialog.ui
index 245e33d..5936447 100644
--- a/deluge/ui/gtkui/glade/preferences_dialog.ui
+++ b/deluge/ui/gtkui/glade/preferences_dialog.ui
@@ -2,6 +2,52 @@
<interface>
<requires lib="gtk+" version="2.16"/>
<!-- interface-naming-policy toplevel-contextual -->
+ <object class="GtkAdjustment" id="adjustment_cache_size">
+ <property name="upper">999999</property>
+ <property name="value">100</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_outgoing_port_max">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_outgoing_port_min">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_port_max">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_port_min">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_proxy_port_dht">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_proxy_port_peer">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_proxy_port_tracker">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment_spin_proxy_port_web_seed">
+ <property name="upper">65535</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
<object class="GtkAdjustment" id="adjustment_cache_expiry">
<property name="lower">1</property>
<property name="upper">32000</property>
@@ -9,12 +55,6 @@
<property name="step_increment">1</property>
<property name="page_increment">10</property>
</object>
- <object class="GtkAdjustment" id="adjustment_cache_size">
- <property name="upper">999999</property>
- <property name="value">100</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
<object class="GtkAdjustment" id="adjustment_share_ratio">
<property name="lower">0.5</property>
<property name="upper">100</property>
@@ -106,46 +146,6 @@
<property name="step_increment">1</property>
<property name="page_increment">10</property>
</object>
- <object class="GtkAdjustment" id="adjustment_spin_outgoing_port_max">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_outgoing_port_min">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_port_max">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_port_min">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_proxy_port_dht">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_proxy_port_peer">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_proxy_port_tracker">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
- <object class="GtkAdjustment" id="adjustment_spin_proxy_port_web_seed">
- <property name="upper">65535</property>
- <property name="step_increment">1</property>
- <property name="page_increment">10</property>
- </object>
<object class="GtkAdjustment" id="adjustment_spin_seed_time_limit">
<property name="lower">-1</property>
<property name="upper">9999</property>
@@ -410,6 +410,7 @@
<object class="GtkTreeView" id="treeview">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <property name="headers_visible">False</property>
</object>
</child>
</object>
@@ -938,6 +939,55 @@ used sparingly.</property>
</packing>
</child>
<child>
+ <object class="GtkFrame" id="frame31">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label_xalign">0</property>
+ <property name="shadow_type">none</property>
+ <child>
+ <object class="GtkAlignment" id="alignment51">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="xscale">0</property>
+ <property name="top_padding">1</property>
+ <property name="left_padding">12</property>
+ <child>
+ <object class="GtkEntry" id="entry_interface">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="tooltip_text" translatable="yes">The IP address of the interface to listen for incoming bittorrent connections on. Leave this empty if you want to use the default.</property>
+ <property name="max_length">15</property>
+ <property name="width_chars">15</property>
+ <property name="truncate_multiline">True</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child type="label">
+ <object class="GtkLabel" id="label110">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="ypad">2</property>
+ <property name="label" translatable="yes">Incoming Address</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ </attributes>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="padding">2</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkFrame" id="frame1">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -947,87 +997,13 @@ used sparingly.</property>
<object class="GtkAlignment" id="alignment1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="top_padding">2</property>
- <property name="bottom_padding">2</property>
+ <property name="top_padding">1</property>
<property name="left_padding">12</property>
<child>
<object class="GtkVBox" id="vbox3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <object class="GtkHBox" id="hbox2">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="spacing">20</property>
- <child>
- <object class="GtkCheckButton" id="chk_random_port">
- <property name="label" translatable="yes">Use Random Ports</property>
- <property name="use_action_appearance">False</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">False</property>
- <property name="tooltip_text" translatable="yes">Deluge will automatically choose a different port to use every time.</property>
- <property name="draw_indicator">True</property>
- <signal name="toggled" handler="on_toggle" swapped="no"/>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkHBox" id="hbox3">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkLabel" id="label3">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">1</property>
- <property name="label" translatable="yes">Active Port:</property>
- <property name="justify">right</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkLabel" id="active_port_label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label">0000</property>
- <property name="width_chars">5</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">1</property>
- </packing>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">1</property>
- </packing>
- </child>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
<object class="GtkHBox" id="hbox1">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -1103,41 +1079,117 @@ used sparingly.</property>
</packing>
</child>
<child>
+ <object class="GtkCheckButton" id="chk_random_port">
+ <property name="label" translatable="yes">Random</property>
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Uses random ports in range 49152 to 65525</property>
+ <property name="draw_indicator">True</property>
+ <signal name="toggled" handler="on_toggle" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkHBox" id="hbox3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="spacing">10</property>
+ <child>
+ <object class="GtkHBox" id="hbox4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Active Port:</property>
+ <property name="justify">right</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="active_port_label">
+ <property name="width_request">50</property>
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="label">0</property>
+ <property name="width_chars">5</property>
+ <attributes>
+ <attribute name="style" value="italic"/>
+ </attributes>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkButton" id="btn_testport">
<property name="label" translatable="yes">Test Active Port</property>
<property name="use_action_appearance">False</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
+ <property name="image_position">right</property>
<signal name="clicked" handler="on_test_port_clicked" swapped="no"/>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">4</property>
+ <property name="position">1</property>
</packing>
</child>
<child>
<object class="GtkAlignment" id="alignment48">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="left_padding">5</property>
+ <property name="xalign">0</property>
<child>
<object class="GtkImage" id="port_img">
<property name="can_focus">False</property>
- <property name="stock">gtk-missing-image</property>
+ <property name="stock">gtk-dialog-question</property>
</object>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">5</property>
+ <property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
+ <property name="expand">False</property>
<property name="fill">True</property>
<property name="padding">5</property>
<property name="position">1</property>
@@ -1151,6 +1203,7 @@ used sparingly.</property>
<object class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="ypad">2</property>
<property name="label" translatable="yes">Incoming Ports</property>
<attributes>
<attribute name="weight" value="bold"/>
@@ -1161,8 +1214,8 @@ used sparingly.</property>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">2</property>
+ <property name="padding">2</property>
+ <property name="position">3</property>
</packing>
</child>
<child>
@@ -1175,22 +1228,18 @@ used sparingly.</property>
<object class="GtkAlignment" id="alignment34">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="top_padding">5</property>
+ <property name="top_padding">1</property>
<property name="left_padding">12</property>
<child>
- <object class="GtkVBox" id="vbox25">
+ <object class="GtkHBox" id="hbox14">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">5</property>
<child>
- <object class="GtkCheckButton" id="chk_random_outgoing_ports">
- <property name="label" translatable="yes">Use Random Ports</property>
- <property name="use_action_appearance">False</property>
+ <object class="GtkLabel" id="label77">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">False</property>
- <property name="draw_indicator">True</property>
- <signal name="toggled" handler="on_toggle" swapped="no"/>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">From:</property>
</object>
<packing>
<property name="expand">False</property>
@@ -1199,157 +1248,90 @@ used sparingly.</property>
</packing>
</child>
<child>
- <object class="GtkHBox" id="hbox14">
+ <object class="GtkSpinButton" id="spin_outgoing_port_min">
<property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="spacing">5</property>
- <child>
- <object class="GtkLabel" id="label77">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">From:</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkSpinButton" id="spin_outgoing_port_min">
- <property name="visible">True</property>
- <property name="sensitive">False</property>
- <property name="can_focus">True</property>
- <property name="max_length">5</property>
- <property name="xalign">1</property>
- <property name="primary_icon_activatable">False</property>
- <property name="secondary_icon_activatable">False</property>
- <property name="primary_icon_sensitive">True</property>
- <property name="secondary_icon_sensitive">True</property>
- <property name="adjustment">adjustment_spin_outgoing_port_min</property>
- <property name="climb_rate">1</property>
- <property name="snap_to_ticks">True</property>
- <property name="numeric">True</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkLabel" id="label78">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">To:</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">2</property>
- </packing>
- </child>
- <child>
- <object class="GtkSpinButton" id="spin_outgoing_port_max">
- <property name="visible">True</property>
- <property name="sensitive">False</property>
- <property name="can_focus">True</property>
- <property name="max_length">5</property>
- <property name="xalign">1</property>
- <property name="primary_icon_activatable">False</property>
- <property name="secondary_icon_activatable">False</property>
- <property name="primary_icon_sensitive">True</property>
- <property name="secondary_icon_sensitive">True</property>
- <property name="adjustment">adjustment_spin_outgoing_port_max</property>
- <property name="climb_rate">1</property>
- <property name="snap_to_ticks">True</property>
- <property name="numeric">True</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">3</property>
- </packing>
- </child>
+ <property name="sensitive">False</property>
+ <property name="can_focus">True</property>
+ <property name="max_length">5</property>
+ <property name="xalign">1</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
+ <property name="adjustment">adjustment_spin_outgoing_port_min</property>
+ <property name="climb_rate">1</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
</object>
<packing>
- <property name="expand">True</property>
+ <property name="expand">False</property>
<property name="fill">True</property>
+ <property name="padding">5</property>
<property name="position">1</property>
</packing>
</child>
- </object>
- </child>
- </object>
- </child>
- <child type="label">
- <object class="GtkLabel" id="label79">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Outgoing Ports</property>
- <attributes>
- <attribute name="weight" value="bold"/>
- </attributes>
- </object>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">3</property>
- </packing>
- </child>
- <child>
- <object class="GtkFrame" id="frame31">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label_xalign">0</property>
- <property name="shadow_type">none</property>
- <child>
- <object class="GtkAlignment" id="alignment51">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="top_padding">2</property>
- <property name="bottom_padding">2</property>
- <property name="left_padding">12</property>
- <child>
- <object class="GtkHBox" id="hbox21">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
<child>
- <object class="GtkEntry" id="entry_interface">
+ <object class="GtkLabel" id="label78">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">To:</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkSpinButton" id="spin_outgoing_port_max">
+ <property name="visible">True</property>
+ <property name="sensitive">False</property>
<property name="can_focus">True</property>
- <property name="tooltip_text" translatable="yes">Enter the IP address of the interface to listen for incoming bittorrent connections on. Leave this empty if you want to use the default.</property>
- <property name="max_length">60</property>
- <property name="invisible_char">●</property>
- <property name="width_chars">30</property>
- <property name="truncate_multiline">True</property>
+ <property name="max_length">5</property>
+ <property name="xalign">1</property>
<property name="primary_icon_activatable">False</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
+ <property name="adjustment">adjustment_spin_outgoing_port_max</property>
+ <property name="climb_rate">1</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
+ <property name="fill">True</property>
+ <property name="padding">5</property>
+ <property name="position">3</property>
</packing>
</child>
<child>
- <placeholder/>
+ <object class="GtkCheckButton" id="chk_random_outgoing_ports">
+ <property name="label" translatable="yes">Random</property>
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Uses random ports in range 49152 to 65525</property>
+ <property name="draw_indicator">True</property>
+ <signal name="toggled" handler="on_toggle" swapped="no"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">4</property>
+ </packing>
</child>
</object>
</child>
</object>
</child>
<child type="label">
- <object class="GtkLabel" id="label110">
+ <object class="GtkLabel" id="label79">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Interface</property>
+ <property name="ypad">2</property>
+ <property name="label" translatable="yes">Outgoing Ports</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
@@ -1359,78 +1341,159 @@ used sparingly.</property>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
+ <property name="padding">2</property>
<property name="position">4</property>
</packing>
</child>
<child>
- <object class="GtkFrame" id="frame2">
+ <object class="GtkFrame" id="frame4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <object class="GtkAlignment" id="alignment2">
+ <object class="GtkAlignment" id="alignment4">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="top_padding">2</property>
- <property name="bottom_padding">2</property>
<property name="left_padding">12</property>
<child>
- <object class="GtkVBox" id="vbox4">
+ <object class="GtkHBox" id="hbox6">
<property name="visible">True</property>
<property name="can_focus">False</property>
+ <property name="spacing">5</property>
<child>
- <object class="GtkHBox" id="hbox4">
+ <object class="GtkTable" id="table7">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="spacing">5</property>
+ <property name="n_rows">2</property>
+ <property name="n_columns">2</property>
<child>
- <object class="GtkLabel" id="label80">
+ <object class="GtkComboBox" id="combo_encout">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="tooltip_text" translatable="yes">The TOS byte set in the IP header of every packet sent to peers (including web seeds). Expects a Hex value.</property>
- <property name="label" translatable="yes">Peer TOS Byte:</property>
+ <property name="model">liststore3</property>
+ <signal name="changed" handler="on_combo_encryption_changed" swapped="no"/>
+ <child>
+ <object class="GtkCellRendererText" id="cellrenderertext3"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_padding">5</property>
</packing>
</child>
<child>
- <object class="GtkEntry" id="entry_peer_tos">
+ <object class="GtkComboBox" id="combo_encin">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="width_chars">4</property>
- <property name="text">0x00</property>
- <property name="truncate_multiline">True</property>
- <property name="primary_icon_activatable">False</property>
- <property name="secondary_icon_activatable">False</property>
- <property name="primary_icon_sensitive">True</property>
- <property name="secondary_icon_sensitive">True</property>
+ <property name="can_focus">False</property>
+ <property name="model">liststore1</property>
+ <signal name="changed" handler="on_combo_encryption_changed" swapped="no"/>
+ <child>
+ <object class="GtkCellRendererText" id="cellrenderertext1"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">1</property>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="x_padding">5</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label8">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">1</property>
+ <property name="label" translatable="yes">Outgoing:</property>
+ </object>
+ <packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
</packing>
</child>
+ <child>
+ <object class="GtkLabel" id="label7">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">1</property>
+ <property name="label" translatable="yes">Incoming:</property>
+ </object>
+ </child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
+ <child>
+ <object class="GtkAlignment" id="alignment11">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="yscale">0</property>
+ <child>
+ <object class="GtkHBox" id="hbox15">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkLabel" id="label9">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="xalign">0</property>
+ <property name="xpad">5</property>
+ <property name="label" translatable="yes">Level:</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkComboBox" id="combo_enclevel">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="model">liststore2</property>
+ <child>
+ <object class="GtkCellRendererText" id="cellrenderertext2"/>
+ <attributes>
+ <attribute name="text">0</attribute>
+ </attributes>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
</object>
</child>
</object>
</child>
<child type="label">
- <object class="GtkLabel" id="label5">
+ <object class="GtkLabel" id="label10">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">TOS</property>
+ <property name="ypad">2</property>
+ <property name="label" translatable="yes">Encryption</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
@@ -1439,7 +1502,7 @@ used sparingly.</property>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">True</property>
+ <property name="fill">False</property>
<property name="padding">5</property>
<property name="position">5</property>
</packing>
@@ -1461,9 +1524,10 @@ used sparingly.</property>
<object class="GtkTable" id="table8">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="n_rows">2</property>
+ <property name="n_rows">3</property>
<property name="n_columns">3</property>
- <property name="column_spacing">5</property>
+ <property name="column_spacing">6</property>
+ <property name="row_spacing">1</property>
<child>
<object class="GtkCheckButton" id="chk_upnp">
<property name="label" translatable="yes">UPnP</property>
@@ -1513,7 +1577,6 @@ used sparingly.</property>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -1533,7 +1596,6 @@ used sparingly.</property>
<property name="right_attach">3</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
- <property name="x_options">GTK_FILL</property>
</packing>
</child>
<child>
@@ -1572,200 +1634,49 @@ used sparingly.</property>
</packing>
</child>
<child>
- <placeholder/>
- </child>
- </object>
- </child>
- </object>
- </child>
- <child type="label">
- <object class="GtkLabel" id="label6">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Network Extras</property>
- <attributes>
- <attribute name="weight" value="bold"/>
- </attributes>
- </object>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">5</property>
- <property name="position">6</property>
- </packing>
- </child>
- <child>
- <object class="GtkFrame" id="frame4">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label_xalign">0</property>
- <property name="shadow_type">none</property>
- <child>
- <object class="GtkAlignment" id="alignment4">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="top_padding">2</property>
- <property name="bottom_padding">2</property>
- <property name="left_padding">12</property>
- <child>
- <object class="GtkHBox" id="hbox6">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="spacing">5</property>
- <child>
- <object class="GtkVBox" id="vbox10">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkLabel" id="label7">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">1</property>
- <property name="label" translatable="yes">Inbound:</property>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkLabel" id="label9">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Level:</property>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkVBox" id="vbox12">
+ <object class="GtkHBox" id="hbox5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <object class="GtkComboBox" id="combo_encin">
+ <object class="GtkLabel" id="label_peer_tos">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="model">liststore1</property>
- <child>
- <object class="GtkCellRendererText" id="cellrenderertext1"/>
- <attributes>
- <attribute name="text">0</attribute>
- </attributes>
- </child>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkComboBox" id="combo_enclevel">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="model">liststore2</property>
- <child>
- <object class="GtkCellRendererText" id="cellrenderertext2"/>
- <attributes>
- <attribute name="text">0</attribute>
- </attributes>
- </child>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkVBox" id="vbox15">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkHBox" id="hbox15">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkLabel" id="label8">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">1</property>
- <property name="label" translatable="yes">Outbound:</property>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
- <object class="GtkComboBox" id="combo_encout">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="model">liststore3</property>
- <child>
- <object class="GtkCellRendererText" id="cellrenderertext3"/>
- <attributes>
- <attribute name="text">0</attribute>
- </attributes>
- </child>
- </object>
- <packing>
- <property name="expand">False</property>
- <property name="fill">True</property>
- <property name="position">1</property>
- </packing>
- </child>
+ <property name="tooltip_text" translatable="yes">TOS can help with network conjestion. This value is included in every IPv4 packet header sent to peers (inc. web seeds).
+Requires a Hex value.</property>
+ <property name="xpad">3</property>
+ <property name="label" translatable="yes">Peer TOS Byte:</property>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
<child>
- <object class="GtkCheckButton" id="chk_pref_rc4">
- <property name="label" translatable="yes">Encrypt entire stream</property>
- <property name="use_action_appearance">False</property>
+ <object class="GtkEntry" id="entry_peer_tos">
+ <property name="height_request">25</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="receives_default">False</property>
- <property name="use_underline">True</property>
- <property name="draw_indicator">True</property>
+ <property name="max_length">4</property>
+ <property name="width_chars">4</property>
+ <property name="text">0x00</property>
+ <property name="truncate_multiline">True</property>
+ <property name="primary_icon_activatable">False</property>
+ <property name="secondary_icon_activatable">False</property>
+ <property name="primary_icon_sensitive">True</property>
+ <property name="secondary_icon_sensitive">True</property>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">True</property>
- <property name="padding">3</property>
+ <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
</packing>
</child>
</object>
@@ -1773,10 +1684,11 @@ used sparingly.</property>
</object>
</child>
<child type="label">
- <object class="GtkLabel" id="label10">
+ <object class="GtkLabel" id="label6">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Encryption</property>
+ <property name="ypad">2</property>
+ <property name="label" translatable="yes">Network Extras</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
@@ -1785,9 +1697,9 @@ used sparingly.</property>
</object>
<packing>
<property name="expand">False</property>
- <property name="fill">False</property>
+ <property name="fill">True</property>
<property name="padding">5</property>
- <property name="position">7</property>
+ <property name="position">6</property>
</packing>
</child>
</object>
@@ -2521,6 +2433,35 @@ used sparingly.</property>
</packing>
</child>
<child>
+ <object class="GtkCheckButton" id="piecesbar_toggle">
+ <property name="use_action_appearance">False</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="tooltip_text" translatable="yes">Besides being experimental, using the pieces bar
+will increase the bandwidth used between client
+and daemon(does not apply in classic mode).
+Use at your own risk if you wish to help us debug
+this new feature.</property>
+ <property name="draw_indicator">True</property>
+ <signal name="toggled" handler="on_piecesbar_toggle_toggled" swapped="no"/>
+ <child>
+ <object class="GtkLabel" id="label62">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Show a pieces bar in the torrent's
+status tab (&lt;b&gt;EXPERIMENTAL!!!&lt;/b&gt;)</property>
+ <property name="use_markup">True</property>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkExpander" id="piecebar_colors_expander">
<property name="can_focus">True</property>
<child>
@@ -2756,35 +2697,6 @@ used sparingly.</property>
<property name="position">2</property>
</packing>
</child>
- <child>
- <object class="GtkCheckButton" id="piecesbar_toggle">
- <property name="use_action_appearance">False</property>
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">False</property>
- <property name="tooltip_text" translatable="yes">Besides being experimental, using the pieces bar
-will increase the bandwidth used between client
-and daemon(does not apply in classic mode).
-Use at your own risk if you wish to help us debug
-this new feature.</property>
- <property name="draw_indicator">True</property>
- <signal name="toggled" handler="on_piecesbar_toggle_toggled" swapped="no"/>
- <child>
- <object class="GtkLabel" id="label62">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Show a pieces bar in the torrent's
-status tab (&lt;b&gt;EXPERIMENTAL!!!&lt;/b&gt;)</property>
- <property name="use_markup">True</property>
- </object>
- </child>
- </object>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">2</property>
- </packing>
- </child>
</object>
</child>
</object>
diff --git a/deluge/ui/gtkui/preferences.py b/deluge/ui/gtkui/preferences.py
index 94be00b..18db272 100644
--- a/deluge/ui/gtkui/preferences.py
+++ b/deluge/ui/gtkui/preferences.py
@@ -161,6 +161,7 @@ class Preferences(component.Component):
"on_button_rescan_plugins_clicked": self._on_button_rescan_plugins_clicked,
"on_button_find_plugins_clicked": self._on_button_find_plugins_clicked,
"on_button_cache_refresh_clicked": self._on_button_cache_refresh_clicked,
+ "on_combo_encryption_changed": self._on_combo_encryption_changed,
"on_combo_proxy_type_changed": self._on_combo_proxy_type_changed,
"on_button_associate_magnet_clicked": self._on_button_associate_magnet_clicked,
"on_accounts_add_clicked": self._on_accounts_add_clicked,
@@ -337,7 +338,6 @@ class Preferences(component.Component):
"combo_encin": ("active", self.core_config["enc_in_policy"]),
"combo_encout": ("active", self.core_config["enc_out_policy"]),
"combo_enclevel": ("active", self.core_config["enc_level"]),
- "chk_pref_rc4": ("active", self.core_config["enc_prefer_rc4"]),
"spin_max_connections_global": \
("value", self.core_config["max_connections_global"]),
"spin_max_download": \
@@ -493,7 +493,6 @@ class Preferences(component.Component):
"combo_encin",
"combo_encout",
"combo_enclevel",
- "chk_pref_rc4",
"spin_max_connections_global",
"spin_max_download",
"spin_max_upload",
@@ -696,8 +695,6 @@ class Preferences(component.Component):
self.builder.get_object("combo_encout").get_active()
new_core_config["enc_level"] = \
self.builder.get_object("combo_enclevel").get_active()
- new_core_config["enc_prefer_rc4"] = \
- self.builder.get_object("chk_pref_rc4").get_active()
## Bandwidth tab ##
new_core_config["max_connections_global"] = \
@@ -1077,6 +1074,17 @@ class Preferences(component.Component):
def _on_button_find_plugins_clicked(self, widget):
deluge.common.open_url_in_browser("http://dev.deluge-torrent.org/wiki/Plugins")
+ def _on_combo_encryption_changed(self, widget):
+ combo_encin = self.builder.get_object("combo_encin").get_active()
+ combo_encout = self.builder.get_object("combo_encout").get_active()
+ combo_enclevel = self.builder.get_object("combo_enclevel")
+
+ # If incoming and outgoing both set to disabled, disable level combobox
+ if combo_encin == 2 and combo_encout == 2:
+ combo_enclevel.set_sensitive(False)
+ else:
+ combo_enclevel.set_sensitive(True)
+
def _on_combo_proxy_type_changed(self, widget):
name = widget.get_name().replace("combo_proxy_type_", "")
proxy_type = widget.get_model()[widget.get_active()][0]
diff --git a/deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js b/deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js
index a259529..7c306ba 100644
--- a/deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js
+++ b/deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js
@@ -1,6 +1,6 @@
/*!
* Deluge.preferences.EncryptionPage.js
- *
+ *
* Copyright (c) Damien Churchill 2009-2010 <damoxc@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
@@ -39,12 +39,12 @@ Deluge.preferences.Encryption = Ext.extend(Ext.form.FormPanel, {
border: false,
title: _('Encryption'),
-
+
initComponent: function() {
Deluge.preferences.Encryption.superclass.initComponent.call(this);
var optMan = deluge.preferences.getOptionsManager();
-
+
var fieldset = this.add({
xtype: 'fieldset',
border: false,
@@ -54,7 +54,8 @@ Deluge.preferences.Encryption = Ext.extend(Ext.form.FormPanel, {
width: 300
});
optMan.bind('enc_in_policy', fieldset.add({
- fieldLabel: _('Inbound'),
+ fieldLabel: _('Incoming:'),
+ labelSeparator : '',
mode: 'local',
width: 150,
store: new Ext.data.ArrayStore({
@@ -71,7 +72,8 @@ Deluge.preferences.Encryption = Ext.extend(Ext.form.FormPanel, {
displayField: 'text'
}));
optMan.bind('enc_out_policy', fieldset.add({
- fieldLabel: _('Outbound'),
+ fieldLabel: _('Outgoing:'),
+ labelSeparator : '',
mode: 'local',
width: 150,
store: new Ext.data.SimpleStore({
@@ -88,7 +90,8 @@ Deluge.preferences.Encryption = Ext.extend(Ext.form.FormPanel, {
displayField: 'text'
}));
optMan.bind('enc_level', fieldset.add({
- fieldLabel: _('Level'),
+ fieldLabel: _('Level:'),
+ labelSeparator : '',
mode: 'local',
width: 150,
store: new Ext.data.SimpleStore({
@@ -104,12 +107,5 @@ Deluge.preferences.Encryption = Ext.extend(Ext.form.FormPanel, {
valueField: 'id',
displayField: 'text'
}));
- optMan.bind('enc_prefer_rc4', fieldset.add({
- xtype: 'checkbox',
- name: 'enc_prefer_rc4',
- height: 40,
- hideLabel: true,
- boxLabel: _('Encrypt entire stream')
- }));
}
});
diff --git a/deluge/ui/web/js/deluge-all/preferences/NetworkPage.js b/deluge/ui/web/js/deluge-all/preferences/NetworkPage.js
index 250a070..ad2a79e 100644
--- a/deluge/ui/web/js/deluge-all/preferences/NetworkPage.js
+++ b/deluge/ui/web/js/deluge-all/preferences/NetworkPage.js
@@ -45,6 +45,22 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
Deluge.preferences.Network.superclass.initComponent.call(this);
var optMan = deluge.preferences.getOptionsManager();
+ fieldset = this.add({
+ xtype: 'fieldset',
+ border: false,
+ title: _('Incoming Address'),
+ style: 'margin-bottom: 5px; padding-bottom: 0px;',
+ autoHeight: true,
+ labelWidth: 1,
+ defaultType: 'textfield'
+ });
+ optMan.bind('listen_interface', fieldset.add({
+ name: 'listen_interface',
+ fieldLabel: '',
+ labelSeparator: '',
+ width: 200
+ }));
+
var fieldset = this.add({
xtype: 'fieldset',
border: false,
@@ -79,7 +95,8 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
style: 'margin-right: 10px;'
},
items: [{
- fieldLabel: 'From',
+ fieldLabel: 'From:',
+ labelSeparator: '',
strategy: {
xtype: 'number',
decimalPrecision: 0,
@@ -87,7 +104,8 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
maxValue: 99999
}
}, {
- fieldLabel: 'To',
+ fieldLabel: 'To:',
+ labelSeparator: '',
strategy: {
xtype: 'number',
decimalPrecision: 0,
@@ -132,7 +150,8 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
style: 'margin-right: 10px;'
},
items: [{
- fieldLabel: 'From',
+ fieldLabel: 'From:',
+ labelSeparator: '',
strategy: {
xtype: 'number',
decimalPrecision: 0,
@@ -140,7 +159,8 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
maxValue: 99999
}
}, {
- fieldLabel: 'To',
+ fieldLabel: 'To:',
+ labelSeparator: '',
strategy: {
xtype: 'number',
decimalPrecision: 0,
@@ -154,37 +174,6 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
fieldset = this.add({
xtype: 'fieldset',
border: false,
- title: _('Network Interface'),
- style: 'margin-bottom: 5px; padding-bottom: 0px;',
- autoHeight: true,
- labelWidth: 1,
- defaultType: 'textfield'
- });
- optMan.bind('listen_interface', fieldset.add({
- name: 'listen_interface',
- fieldLabel: '',
- labelSeparator: '',
- width: 200
- }));
-
- fieldset = this.add({
- xtype: 'fieldset',
- border: false,
- title: _('TOS'),
- style: 'margin-bottom: 5px; padding-bottom: 0px;',
- bodyStyle: 'margin: 0px; padding: 0px',
- autoHeight: true,
- defaultType: 'textfield'
- });
- optMan.bind('peer_tos', fieldset.add({
- name: 'peer_tos',
- fieldLabel: _('Peer TOS Byte'),
- width: 80
- }));
-
- fieldset = this.add({
- xtype: 'fieldset',
- border: false,
title: _('Network Extras'),
autoHeight: true,
layout: 'table',
@@ -233,5 +222,21 @@ Deluge.preferences.Network = Ext.extend(Ext.form.FormPanel, {
ctCls: 'x-deluge-indent-checkbox',
name: 'lt_tex'
}));
+
+ fieldset = this.add({
+ xtype: 'fieldset',
+ border: false,
+ title: _('Type Of Service'),
+ style: 'margin-bottom: 5px; padding-bottom: 0px;',
+ bodyStyle: 'margin: 0px; padding: 0px',
+ autoHeight: true,
+ defaultType: 'textfield'
+ });
+ optMan.bind('peer_tos', fieldset.add({
+ name: 'peer_tos',
+ fieldLabel: _('Peer TOS Byte:'),
+ labelSeparator: '',
+ width: 40
+ }));
}
});