summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDjLegolas <DjLegolas@users.noreply.github.com>2017-08-29 11:29:39 +0300
committerCalum Lind <calumlind+deluge@gmail.com>2017-10-14 21:30:45 +0100
commit510a8b50b213cab804d693a5f122f9c0d9dd1fb3 (patch)
treeee3e6d1af83ea2aec7dddd0631d6d925680f3b33
parentd190f149d1055d5e41736c4d4ca0e2764e7791b7 (diff)
downloaddeluge-510a8b50b213cab804d693a5f122f9c0d9dd1fb3.zip
deluge-510a8b50b213cab804d693a5f122f9c0d9dd1fb3.tar.gz
deluge-510a8b50b213cab804d693a5f122f9c0d9dd1fb3.tar.bz2
[AutoAdd] Update gtkui from libglade to gtkbuilder
-rw-r--r--deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.ui (renamed from deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.glade)633
-rw-r--r--deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.ui (renamed from deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.glade)91
-rw-r--r--deluge/plugins/AutoAdd/deluge/plugins/autoadd/gtkui.py223
3 files changed, 483 insertions, 464 deletions
diff --git a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.glade b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.ui
index 0a38c60..e6ba56f 100644
--- a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.glade
+++ b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/autoadd_options.ui
@@ -1,33 +1,63 @@
<?xml version="1.0" encoding="UTF-8"?>
-<glade-interface>
- <!-- interface-requires gtk+ 2.16 -->
+<interface>
+ <requires lib="gtk+" version="2.24"/>
<!-- interface-naming-policy toplevel-contextual -->
- <widget class="GtkDialog" id="options_dialog">
+ <object class="GtkAdjustment" id="adjustment1">
+ <property name="lower">-1</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment2">
+ <property name="lower">-1</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment3">
+ <property name="lower">-1</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment4">
+ <property name="lower">-1</property>
+ <property name="upper">10000</property>
+ <property name="step_increment">1</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkAdjustment" id="adjustment5">
+ <property name="upper">100</property>
+ <property name="value">2</property>
+ <property name="step_increment">0.10000000149</property>
+ <property name="page_increment">10</property>
+ </object>
+ <object class="GtkDialog" id="options_dialog">
<property name="can_focus">False</property>
<property name="title" translatable="yes">Watch Folder Properties</property>
<property name="resizable">False</property>
<property name="modal">True</property>
<property name="type_hint">dialog</property>
- <signal name="close" handler="on_options_dialog_close"/>
+ <signal name="close" handler="on_options_dialog_close" swapped="no"/>
<child internal-child="vbox">
- <widget class="GtkVBox" id="dialog-vbox1">
+ <object class="GtkVBox" id="dialog-vbox1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child internal-child="action_area">
- <widget class="GtkHButtonBox" id="dialog-action_area1">
+ <object class="GtkHButtonBox" id="dialog-action_area1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="layout_style">end</property>
<child>
- <widget class="GtkButton" id="opts_cancel_button">
+ <object class="GtkButton" id="opts_cancel_button">
<property name="label">gtk-cancel</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">False</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_opts_cancel"/>
- </widget>
+ <signal name="clicked" handler="on_opts_cancel" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -35,15 +65,15 @@
</packing>
</child>
<child>
- <widget class="GtkButton" id="opts_add_button">
+ <object class="GtkButton" id="opts_add_button">
<property name="label">gtk-add</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">False</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_opts_add"/>
- </widget>
+ <signal name="clicked" handler="on_opts_add" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -51,22 +81,22 @@
</packing>
</child>
<child>
- <widget class="GtkButton" id="opts_apply_button">
+ <object class="GtkButton" id="opts_apply_button">
<property name="label">gtk-apply</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">False</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_opts_apply"/>
- </widget>
+ <signal name="clicked" handler="on_opts_apply" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
@@ -75,49 +105,49 @@
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox1">
+ <object class="GtkVBox" id="vbox1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkNotebook" id="notebook1">
+ <object class="GtkNotebook" id="notebook1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<child>
- <widget class="GtkVBox" id="vbox2">
+ <object class="GtkVBox" id="vbox2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="border_width">6</property>
<child>
- <widget class="GtkFrame" id="frame2">
+ <object class="GtkFrame" id="frame2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment3">
+ <object class="GtkAlignment" id="alignment3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkVBox" id="vbox6">
+ <object class="GtkVBox" id="vbox6">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkHBox" id="hbox3">
+ <object class="GtkHBox" id="hbox3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkEntry" id="path_entry">
+ <object class="GtkEntry" id="path_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="tooltip" translatable="yes">If a .torrent file is added to this directory,
+ <property name="tooltip_text" translatable="yes">If a .torrent file is added to this directory,
it will be added to the session.</property>
<property name="invisible_char">●</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>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -125,21 +155,21 @@ it will be added to the session.</property>
</packing>
</child>
<child>
- <widget class="GtkFileChooserButton" id="path_chooser">
+ <object class="GtkFileChooserButton" id="path_chooser">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="tooltip" translatable="yes">If a .torrent file is added to this directory,
+ <property name="tooltip_text" translatable="yes">If a .torrent file is added to this directory,
it will be added to the session.</property>
<property name="action">select-folder</property>
<property name="title" translatable="yes">Select A Folder</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -147,37 +177,33 @@ it will be added to the session.</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="enabled">
+ <object class="GtkCheckButton" id="enabled">
<property name="label" translatable="yes">Enable this watch folder</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>
- <signal name="toggled" handler="on_enabled_toggle_toggled"/>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label6">
+ <child type="label">
+ <object class="GtkLabel" id="label6">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Watch Folder&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">False</property>
@@ -188,35 +214,35 @@ it will be added to the session.</property>
<placeholder/>
</child>
<child>
- <widget class="GtkFrame" id="frame1">
+ <object class="GtkFrame" id="frame1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment1">
+ <object class="GtkAlignment" id="alignment1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkAlignment" id="alignment2">
+ <object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkVBox" id="vbox7">
+ <object class="GtkVBox" id="vbox7">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkRadioButton" id="isnt_append_extension">
+ <object class="GtkRadioButton" id="isnt_append_extension">
<property name="label" translatable="yes">Delete .torrent after adding</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
- <property name="tooltip" translatable="yes">Once the torrent is added to the session,
+ <property name="tooltip_text" translatable="yes">Once the torrent is added to the session,
the .torrent will be deleted.</property>
<property name="draw_indicator">True</property>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -224,22 +250,22 @@ the .torrent will be deleted.</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox1">
+ <object class="GtkHBox" id="hbox1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkRadioButton" id="append_extension_toggle">
+ <object class="GtkRadioButton" id="append_extension_toggle">
<property name="label" translatable="yes">Append extension after adding:</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
- <property name="tooltip" translatable="yes">Once the torrent is added to the session,
+ <property name="tooltip_text" translatable="yes">Once the torrent is added to the session,
an extension will be appended to the .torrent
and it will remain in the same directory.</property>
<property name="draw_indicator">True</property>
<property name="group">isnt_append_extension</property>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -247,7 +273,7 @@ and it will remain in the same directory.</property>
</packing>
</child>
<child>
- <widget class="GtkEntry" id="append_extension">
+ <object class="GtkEntry" id="append_extension">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">•</property>
@@ -256,14 +282,14 @@ and it will remain in the same directory.</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -271,31 +297,31 @@ and it will remain in the same directory.</property>
</packing>
</child>
<child>
- <widget class="GtkTable" id="table4">
+ <object class="GtkTable" id="table4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="n_rows">2</property>
<property name="n_columns">2</property>
<child>
- <widget class="GtkRadioButton" id="copy_torrent_toggle">
+ <object class="GtkRadioButton" id="copy_torrent_toggle">
<property name="label" translatable="yes">Copy of .torrent files to:</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
- <property name="tooltip" translatable="yes">Once the torrent is added to the session,
+ <property name="tooltip_text" translatable="yes">Once the torrent is added to the session,
the .torrent will copied to the chosen directory
and deleted from the watch folder.</property>
<property name="draw_indicator">True</property>
<property name="group">isnt_append_extension</property>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
</child>
<child>
- <widget class="GtkHBox" id="hbox7">
+ <object class="GtkHBox" id="hbox7">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkEntry" id="copy_torrent_entry">
+ <object class="GtkEntry" id="copy_torrent_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">•</property>
@@ -303,7 +329,7 @@ and deleted from the watch folder.</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -311,35 +337,35 @@ and deleted from the watch folder.</property>
</packing>
</child>
<child>
- <widget class="GtkFileChooserButton" id="copy_torrent_chooser">
+ <object class="GtkFileChooserButton" id="copy_torrent_chooser">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="action">select-folder</property>
<property name="title" translatable="yes">Select A Folder</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="delete_copy_torrent_toggle">
+ <object class="GtkCheckButton" id="delete_copy_torrent_toggle">
<property name="label" translatable="yes">Delete copy of torrent file on remove</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="has_tooltip">True</property>
- <property name="tooltip" translatable="yes">Once the torrent is deleted from the session,
+ <property name="tooltip_text" translatable="yes">Once the torrent is deleted from the session,
also delete the .torrent file used to add it.</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="right_attach">2</property>
<property name="top_attach">1</property>
@@ -347,31 +373,28 @@ also delete the .torrent file used to add it.</property>
<property name="x_padding">15</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label2">
+ <child type="label">
+ <object class="GtkLabel" id="label2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Torrent File Action&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -379,31 +402,31 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFrame" id="frame3">
+ <object class="GtkFrame" id="frame3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment4">
+ <object class="GtkAlignment" id="alignment4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkVBox" id="vbox3">
+ <object class="GtkVBox" id="vbox3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkCheckButton" id="download_location_toggle">
+ <object class="GtkCheckButton" id="download_location_toggle">
<property name="label" translatable="yes">Set download folder</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
- <property name="tooltip" translatable="yes">This folder will be where the torrent data is downloaded to.</property>
+ <property name="tooltip_text" translatable="yes">This folder will be where the torrent data is downloaded to.</property>
<property name="use_underline">True</property>
<property name="draw_indicator">True</property>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -411,11 +434,11 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox4">
+ <object class="GtkHBox" id="hbox4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkEntry" id="download_location_entry">
+ <object class="GtkEntry" id="download_location_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">●</property>
@@ -423,7 +446,7 @@ also delete the .torrent file used to add it.</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -431,41 +454,38 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFileChooserButton" id="download_location_chooser">
+ <object class="GtkFileChooserButton" id="download_location_chooser">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="action">select-folder</property>
<property name="title" translatable="yes">Select A Folder</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label7">
+ <child type="label">
+ <object class="GtkLabel" id="label7">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Download Folder&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">False</property>
@@ -473,30 +493,30 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFrame" id="frame4">
+ <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>
- <widget class="GtkAlignment" id="alignment6">
+ <object class="GtkAlignment" id="alignment6">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkVBox" id="vbox4">
+ <object class="GtkVBox" id="vbox4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkCheckButton" id="move_completed_toggle">
+ <object class="GtkCheckButton" id="move_completed_toggle">
<property name="label" translatable="yes">Set move completed folder</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -504,11 +524,11 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox5">
+ <object class="GtkHBox" id="hbox5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkEntry" id="move_completed_path_entry">
+ <object class="GtkEntry" id="move_completed_path_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">●</property>
@@ -516,7 +536,7 @@ also delete the .torrent file used to add it.</property>
<property name="secondary_icon_activatable">False</property>
<property name="primary_icon_sensitive">True</property>
<property name="secondary_icon_sensitive">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -524,12 +544,12 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFileChooserButton" id="move_completed_path_chooser">
+ <object class="GtkFileChooserButton" id="move_completed_path_chooser">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="action">select-folder</property>
<property name="title" translatable="yes">Select A Folder</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -537,43 +557,40 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="move_completed">
+ <object class="GtkCheckButton" id="move_completed">
<property name="sensitive">False</property>
<property name="can_focus">False</property>
<property name="receives_default">False</property>
<property name="use_underline">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label8">
+ <child type="label">
+ <object class="GtkLabel" id="label8">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Move Completed&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">False</property>
@@ -581,29 +598,29 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFrame" id="label_frame">
+ <object class="GtkFrame" id="label_frame">
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment15">
+ <object class="GtkAlignment" id="alignment15">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkHBox" id="hbox11">
+ <object class="GtkHBox" id="hbox11">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkCheckButton" id="label_toggle">
+ <object class="GtkCheckButton" id="label_toggle">
<property name="label" translatable="yes">Label: </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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
@@ -611,90 +628,84 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkComboBoxEntry" id="label">
+ <object class="GtkComboBox" id="label">
<property name="visible">True</property>
<property name="can_focus">False</property>
- </widget>
+ <property name="has_entry">True</property>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label17">
+ <child type="label">
+ <object class="GtkLabel" id="label17">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Label&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">5</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label4">
+ <child type="tab">
+ <object class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Main</property>
- </widget>
+ </object>
<packing>
<property name="tab_fill">False</property>
- <property name="type">tab</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox5">
+ <object class="GtkVBox" id="vbox5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="spacing">5</property>
<child>
- <widget class="GtkFrame" id="OwnerFrame">
+ <object class="GtkFrame" id="OwnerFrame">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment5">
+ <object class="GtkAlignment" id="alignment5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkComboBox" id="OwnerCombobox">
+ <object class="GtkComboBox" id="OwnerCombobox">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="has_tooltip">True</property>
- <property name="tooltip" translatable="yes">The user selected here will be the owner of the torrent.</property>
- </widget>
+ <property name="tooltip_text" translatable="yes">The user selected here will be the owner of the torrent.</property>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label3">
+ <child type="label">
+ <object class="GtkLabel" id="label3">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Owner&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -702,18 +713,18 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFrame" id="frame5">
+ <object class="GtkFrame" id="frame5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment11">
+ <object class="GtkAlignment" id="alignment11">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkTable" id="table1">
+ <object class="GtkTable" id="table1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="border_width">3</property>
@@ -722,201 +733,198 @@ also delete the .torrent file used to add it.</property>
<property name="column_spacing">2</property>
<property name="row_spacing">4</property>
<child>
- <widget class="GtkCheckButton" id="max_upload_speed_toggle">
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="max_upload_speed_toggle">
<property name="label" translatable="yes">Max Upload Speed:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="max_connections_toggle">
+ <object class="GtkCheckButton" id="max_connections_toggle">
<property name="label" translatable="yes">Max Connections:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="max_upload_slots_toggle">
+ <object class="GtkCheckButton" id="max_upload_slots_toggle">
<property name="label" translatable="yes">Max Upload Slots:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="max_download_speed">
+ <object class="GtkSpinButton" id="max_download_speed">
<property name="visible">True</property>
<property name="can_focus">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="adjustment">0 -1 10000 1 10 0</property>
+ <property name="adjustment">adjustment1</property>
<property name="climb_rate">1</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="max_upload_speed">
+ <object class="GtkSpinButton" id="max_upload_speed">
<property name="visible">True</property>
<property name="can_focus">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="adjustment">0 -1 10000 1 10 0</property>
+ <property name="adjustment">adjustment2</property>
<property name="climb_rate">1</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<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="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="max_connections">
+ <object class="GtkSpinButton" id="max_connections">
<property name="visible">True</property>
<property name="can_focus">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="adjustment">0 -1 10000 1 10 0</property>
+ <property name="adjustment">adjustment3</property>
<property name="climb_rate">1</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="max_upload_slots">
+ <object class="GtkSpinButton" id="max_upload_slots">
<property name="visible">True</property>
<property name="can_focus">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="adjustment">0 -1 10000 1 10 0</property>
+ <property name="adjustment">adjustment4</property>
<property name="climb_rate">1</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label14">
+ <object class="GtkLabel" id="label14">
<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">KiB/s</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label15">
+ <object class="GtkLabel" id="label15">
<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">KiB/s</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">2</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>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="max_download_speed_toggle">
+ <object class="GtkCheckButton" id="max_download_speed_toggle">
<property name="label" translatable="yes">Max Download Speed:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label1">
+ <child type="label">
+ <object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Bandwidth&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -924,18 +932,18 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkFrame" id="frame6">
+ <object class="GtkFrame" id="frame6">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkAlignment" id="alignment12">
+ <object class="GtkAlignment" id="alignment12">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkTable" id="table2">
+ <object class="GtkTable" id="table2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="n_rows">6</property>
@@ -943,21 +951,33 @@ also delete the .torrent file used to add it.</property>
<property name="column_spacing">2</property>
<property name="row_spacing">4</property>
<child>
- <widget class="GtkAlignment" id="alignment13">
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="alignment13">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkCheckButton" id="stop_at_ratio_toggle">
+ <object class="GtkCheckButton" id="stop_at_ratio_toggle">
<property name="label" translatable="yes">Stop seed at ratio:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
@@ -965,83 +985,83 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkAlignment" id="alignment14">
+ <object class="GtkAlignment" id="alignment14">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="yalign">0</property>
<property name="left_padding">12</property>
<child>
- <widget class="GtkCheckButton" id="remove_at_ratio">
+ <object class="GtkCheckButton" id="remove_at_ratio">
<property name="label" translatable="yes">Remove at ratio</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>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="top_attach">4</property>
<property name="bottom_attach">5</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="auto_managed_toggle">
+ <object class="GtkCheckButton" id="auto_managed_toggle">
<property name="label" translatable="yes">Auto Managed:</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>
- <signal name="toggled" handler="on_toggle_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="remove_at_ratio_toggle">
+ <object class="GtkCheckButton" id="remove_at_ratio_toggle">
<property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_underline">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
<property name="top_attach">4</property>
<property name="bottom_attach">5</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="stop_ratio_toggle">
+ <object class="GtkCheckButton" id="stop_ratio_toggle">
<property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_underline">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">4</property>
<property name="bottom_attach">5</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="stop_ratio">
+ <object class="GtkSpinButton" id="stop_ratio">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">●</property>
@@ -1049,25 +1069,25 @@ also delete the .torrent file used to add it.</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">2 0 100 0.10000000149 10 0</property>
+ <property name="adjustment">adjustment5</property>
<property name="climb_rate">1</property>
<property name="digits">1</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="auto_managed_box">
+ <object class="GtkHBox" id="auto_managed_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="homogeneous">True</property>
<child>
- <widget class="GtkRadioButton" id="auto_managed">
+ <object class="GtkRadioButton" id="auto_managed">
<property name="label">gtk-yes</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1075,7 +1095,7 @@ also delete the .torrent file used to add it.</property>
<property name="use_stock">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -1083,7 +1103,7 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkRadioButton" id="isnt_auto_managed">
+ <object class="GtkRadioButton" id="isnt_auto_managed">
<property name="label">gtk-no</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1091,14 +1111,14 @@ also delete the .torrent file used to add it.</property>
<property name="use_stock">True</property>
<property name="draw_indicator">True</property>
<property name="group">auto_managed</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
@@ -1109,40 +1129,43 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="stop_at_ratio">
+ <object class="GtkCheckButton" id="stop_at_ratio">
<property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="use_underline">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="add_paused_toggle">
+ <placeholder/>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="add_paused_toggle">
<property name="label" translatable="yes">Add Paused:</property>
<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_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
</child>
<child>
- <widget class="GtkHBox" id="add_paused_box">
+ <object class="GtkHBox" id="add_paused_box">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="homogeneous">True</property>
<child>
- <widget class="GtkRadioButton" id="add_paused">
+ <object class="GtkRadioButton" id="add_paused">
<property name="label">gtk-yes</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1150,7 +1173,7 @@ also delete the .torrent file used to add it.</property>
<property name="use_stock">True</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -1158,7 +1181,7 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkRadioButton" id="isnt_add_paused">
+ <object class="GtkRadioButton" id="isnt_add_paused">
<property name="label">gtk-no</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -1166,47 +1189,47 @@ also delete the .torrent file used to add it.</property>
<property name="use_stock">True</property>
<property name="draw_indicator">True</property>
<property name="group">add_paused</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="queue_to_top_toggle">
+ <object class="GtkCheckButton" id="queue_to_top_toggle">
<property name="label" translatable="yes">Queue to:</property>
<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_toggled"/>
- </widget>
+ <signal name="toggled" handler="on_toggle_toggled" swapped="no"/>
+ </object>
<packing>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox2">
+ <object class="GtkHBox" id="hbox2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="homogeneous">True</property>
<child>
- <widget class="GtkRadioButton" id="queue_to_top">
+ <object class="GtkRadioButton" id="queue_to_top">
<property name="label" translatable="yes">Top</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="active">True</property>
<property name="draw_indicator">True</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -1214,21 +1237,21 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkRadioButton" id="isnt_queue_to_top">
+ <object class="GtkRadioButton" id="isnt_queue_to_top">
<property name="label" translatable="yes">Bottom</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="draw_indicator">True</property>
<property name="group">queue_to_top</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
@@ -1237,76 +1260,57 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkCheckButton" id="seed_mode">
+ <object class="GtkCheckButton" id="seed_mode">
<property name="label" translatable="yes">Skip File Hash Check</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>
- </widget>
+ </object>
<packing>
<property name="top_attach">5</property>
<property name="bottom_attach">6</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
+ <property name="y_options"/>
</packing>
</child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label16">
+ <child type="label">
+ <object class="GtkLabel" id="label16">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Queue&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
</packing>
</child>
- <child>
- <widget class="GtkLabel" id="label5">
+ <child type="tab">
+ <object class="GtkLabel" id="label5">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Options</property>
- </widget>
+ </object>
<packing>
<property name="position">1</property>
<property name="tab_fill">False</property>
- <property name="type">tab</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
@@ -1314,24 +1318,29 @@ also delete the .torrent file used to add it.</property>
</packing>
</child>
<child>
- <widget class="GtkHButtonBox" id="hbuttonbox2">
+ <object class="GtkHButtonBox" id="hbuttonbox2">
<property name="visible">True</property>
<property name="can_focus">False</property>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
-</glade-interface>
+ <action-widgets>
+ <action-widget response="0">opts_cancel_button</action-widget>
+ <action-widget response="0">opts_add_button</action-widget>
+ <action-widget response="0">opts_apply_button</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.glade b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.ui
index 33ab498..c60e10f 100644
--- a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.glade
+++ b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/data/config.ui
@@ -1,116 +1,129 @@
-<?xml version="1.0"?>
-<glade-interface>
- <!-- interface-requires gtk+ 2.16 -->
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <requires lib="gtk+" version="2.24"/>
<!-- interface-naming-policy toplevel-contextual -->
- <widget class="GtkWindow" id="prefs_window">
+ <object class="GtkWindow" id="prefs_window">
+ <property name="can_focus">False</property>
<child>
- <widget class="GtkHBox" id="hbox9">
+ <object class="GtkHBox" id="hbox9">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
<placeholder/>
</child>
<child>
- <widget class="GtkAlignment" id="prefs_box_1">
+ <object class="GtkAlignment" id="prefs_box_1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
- <widget class="GtkVBox" id="prefs_box">
+ <object class="GtkVBox" id="prefs_box">
<property name="width_request">340</property>
<property name="height_request">390</property>
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="border_width">3</property>
- <property name="orientation">vertical</property>
- <signal name="parent_set" handler="on_parent_set"/>
<child>
- <widget class="GtkFrame" id="frame1">
+ <object class="GtkFrame" id="frame1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
- <widget class="GtkVBox" id="watchdirs_vbox">
+ <object class="GtkVBox" id="watchdirs_vbox">
<property name="visible">True</property>
- <property name="orientation">vertical</property>
+ <property name="can_focus">False</property>
<property name="homogeneous">True</property>
<child>
<placeholder/>
</child>
- </widget>
+ </object>
</child>
- <child>
- <widget class="GtkLabel" id="label1">
+ <child type="label">
+ <object class="GtkLabel" id="label1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<property name="label" translatable="yes">&lt;b&gt;Watch Folders:&lt;/b&gt;</property>
<property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
+ </object>
</child>
- </widget>
+ </object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
- <widget class="GtkHButtonBox" id="hbuttonbox1">
+ <object class="GtkHButtonBox" id="hbuttonbox1">
<property name="visible">True</property>
+ <property name="can_focus">False</property>
<child>
- <widget class="GtkButton" id="add_button">
- <property name="label" translatable="no">gtk-add</property>
+ <object class="GtkButton" id="add_button">
+ <property name="label">gtk-add</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">True</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_add_button_clicked"/>
- </widget>
+ <signal name="clicked" handler="on_add_button_clicked" swapped="no"/>
+ </object>
<packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
<property name="position">0</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="remove_button">
- <property name="label" translatable="no">gtk-remove</property>
+ <object class="GtkButton" id="remove_button">
+ <property name="label">gtk-remove</property>
<property name="visible">True</property>
<property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">True</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_remove_button_clicked"/>
- </widget>
+ <signal name="clicked" handler="on_remove_button_clicked" swapped="no"/>
+ </object>
<packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
<property name="position">1</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="edit_button">
- <property name="label" translatable="no">gtk-edit</property>
+ <object class="GtkButton" id="edit_button">
+ <property name="label">gtk-edit</property>
<property name="visible">True</property>
<property name="sensitive">False</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="receives_default">True</property>
<property name="use_stock">True</property>
- <signal name="clicked" handler="on_edit_button_clicked"/>
- </widget>
+ <signal name="clicked" handler="on_edit_button_clicked" swapped="no"/>
+ </object>
<packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
<property name="position">2</property>
</packing>
</child>
- </widget>
+ </object>
<packing>
<property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
+ </object>
<packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
- </widget>
+ </object>
</child>
- </widget>
-</glade-interface>
+ </object>
+</interface>
diff --git a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/gtkui.py b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/gtkui.py
index 05f9d82..27e3444 100644
--- a/deluge/plugins/AutoAdd/deluge/plugins/autoadd/gtkui.py
+++ b/deluge/plugins/AutoAdd/deluge/plugins/autoadd/gtkui.py
@@ -18,7 +18,6 @@ import logging
import os
import gtk
-import gtk.glade
import deluge.common
import deluge.component as component
@@ -49,127 +48,128 @@ class OptionsDialog(object):
def show(self, options=None, watchdir_id=None):
if options is None:
options = {}
- self.glade = gtk.glade.XML(get_resource('autoadd_options.glade'))
- self.glade.signal_autoconnect({
+ self.builder = gtk.Builder()
+ self.builder.add_from_file(get_resource('autoadd_options.ui'))
+ self.builder.connect_signals({
'on_opts_add': self.on_add,
'on_opts_apply': self.on_apply,
'on_opts_cancel': self.on_cancel,
'on_options_dialog_close': self.on_cancel,
'on_toggle_toggled': self.on_toggle_toggled
})
- self.dialog = self.glade.get_widget('options_dialog')
+ self.dialog = self.builder.get_object('options_dialog')
self.dialog.set_transient_for(component.get('Preferences').pref_dialog)
if watchdir_id:
# We have an existing watchdir_id, we are editing
- self.glade.get_widget('opts_add_button').hide()
- self.glade.get_widget('opts_apply_button').show()
+ self.builder.get_object('opts_add_button').hide()
+ self.builder.get_object('opts_apply_button').show()
self.watchdir_id = watchdir_id
else:
# We don't have an id, adding
- self.glade.get_widget('opts_add_button').show()
- self.glade.get_widget('opts_apply_button').hide()
+ self.builder.get_object('opts_add_button').show()
+ self.builder.get_object('opts_apply_button').hide()
self.watchdir_id = None
self.load_options(options)
self.dialog.run()
def load_options(self, options):
- self.glade.get_widget('enabled').set_active(options.get('enabled', True))
- self.glade.get_widget('append_extension_toggle').set_active(
+ self.builder.get_object('enabled').set_active(options.get('enabled', True))
+ self.builder.get_object('append_extension_toggle').set_active(
options.get('append_extension_toggle', False)
)
- self.glade.get_widget('append_extension').set_text(
+ self.builder.get_object('append_extension').set_text(
options.get('append_extension', '.added')
)
- self.glade.get_widget('download_location_toggle').set_active(
+ self.builder.get_object('download_location_toggle').set_active(
options.get('download_location_toggle', False)
)
- self.glade.get_widget('copy_torrent_toggle').set_active(
+ self.builder.get_object('copy_torrent_toggle').set_active(
options.get('copy_torrent_toggle', False)
)
- self.glade.get_widget('delete_copy_torrent_toggle').set_active(
+ self.builder.get_object('delete_copy_torrent_toggle').set_active(
options.get('delete_copy_torrent_toggle', False)
)
- self.glade.get_widget('seed_mode').set_active(
+ self.builder.get_object('seed_mode').set_active(
options.get('seed_mode', False)
)
self.accounts.clear()
self.labels.clear()
- combobox = self.glade.get_widget('OwnerCombobox')
+ combobox = self.builder.get_object('OwnerCombobox')
combobox_render = gtk.CellRendererText()
combobox.pack_start(combobox_render, True)
combobox.add_attribute(combobox_render, 'text', 0)
combobox.set_model(self.accounts)
- label_widget = self.glade.get_widget('label')
+ label_widget = self.builder.get_object('label')
label_widget.child.set_text(options.get('label', ''))
label_widget.set_model(self.labels)
- label_widget.set_text_column(0)
- self.glade.get_widget('label_toggle').set_active(options.get('label_toggle', False))
+ label_widget.set_entry_text_column(0)
+ self.builder.get_object('label_toggle').set_active(options.get('label_toggle', False))
for spin_id in self.spin_ids + self.spin_int_ids:
- self.glade.get_widget(spin_id).set_value(options.get(spin_id, 0))
- self.glade.get_widget(spin_id + '_toggle').set_active(options.get(spin_id + '_toggle', False))
+ self.builder.get_object(spin_id).set_value(options.get(spin_id, 0))
+ self.builder.get_object(spin_id + '_toggle').set_active(options.get(spin_id + '_toggle', False))
for chk_id in self.chk_ids:
- self.glade.get_widget(chk_id).set_active(bool(options.get(chk_id, True)))
- self.glade.get_widget(chk_id + '_toggle').set_active(options.get(chk_id + '_toggle', False))
+ self.builder.get_object(chk_id).set_active(bool(options.get(chk_id, True)))
+ self.builder.get_object(chk_id + '_toggle').set_active(options.get(chk_id + '_toggle', False))
if not options.get('add_paused', True):
- self.glade.get_widget('isnt_add_paused').set_active(True)
+ self.builder.get_object('isnt_add_paused').set_active(True)
if not options.get('queue_to_top', True):
- self.glade.get_widget('isnt_queue_to_top').set_active(True)
+ self.builder.get_object('isnt_queue_to_top').set_active(True)
if not options.get('auto_managed', True):
- self.glade.get_widget('isnt_auto_managed').set_active(True)
+ self.builder.get_object('isnt_auto_managed').set_active(True)
for field in ['move_completed_path', 'path', 'download_location',
'copy_torrent']:
if client.is_localhost():
- self.glade.get_widget(field + '_chooser').set_current_folder(
+ self.builder.get_object(field + '_chooser').set_current_folder(
options.get(field, os.path.expanduser('~'))
)
- self.glade.get_widget(field + '_chooser').show()
- self.glade.get_widget(field + '_entry').hide()
+ self.builder.get_object(field + '_chooser').show()
+ self.builder.get_object(field + '_entry').hide()
else:
- self.glade.get_widget(field + '_entry').set_text(
+ self.builder.get_object(field + '_entry').set_text(
options.get(field, '')
)
- self.glade.get_widget(field + '_entry').show()
- self.glade.get_widget(field + '_chooser').hide()
+ self.builder.get_object(field + '_entry').show()
+ self.builder.get_object(field + '_chooser').hide()
self.set_sensitive()
def on_core_config(config):
if client.is_localhost():
- self.glade.get_widget('download_location_chooser').set_current_folder(
+ self.builder.get_object('download_location_chooser').set_current_folder(
options.get('download_location', config['download_location'])
)
if options.get('move_completed_toggle', config['move_completed']):
- self.glade.get_widget('move_completed_toggle').set_active(True)
- self.glade.get_widget('move_completed_path_chooser').set_current_folder(
+ self.builder.get_object('move_completed_toggle').set_active(True)
+ self.builder.get_object('move_completed_path_chooser').set_current_folder(
options.get('move_completed_path', config['move_completed_path'])
)
if options.get('copy_torrent_toggle', config['copy_torrent_file']):
- self.glade.get_widget('copy_torrent_toggle').set_active(True)
- self.glade.get_widget('copy_torrent_chooser').set_current_folder(
+ self.builder.get_object('copy_torrent_toggle').set_active(True)
+ self.builder.get_object('copy_torrent_chooser').set_current_folder(
options.get('copy_torrent', config['torrentfiles_location'])
)
else:
- self.glade.get_widget('download_location_entry').set_text(
+ self.builder.get_object('download_location_entry').set_text(
options.get('download_location', config['download_location'])
)
if options.get('move_completed_toggle', config['move_completed']):
- self.glade.get_widget('move_completed_toggle').set_active(
+ self.builder.get_object('move_completed_toggle').set_active(
options.get('move_completed_toggle', False)
)
- self.glade.get_widget('move_completed_path_entry').set_text(
+ self.builder.get_object('move_completed_path_entry').set_text(
options.get('move_completed_path', config['move_completed_path'])
)
if options.get('copy_torrent_toggle', config['copy_torrent_file']):
- self.glade.get_widget('copy_torrent_toggle').set_active(True)
- self.glade.get_widget('copy_torrent_entry').set_text(
+ self.builder.get_object('copy_torrent_toggle').set_active(True)
+ self.builder.get_object('copy_torrent_entry').set_text(
options.get('copy_torrent', config['torrentfiles_location'])
)
if options.get('delete_copy_torrent_toggle', config['del_copy_torrent_file']):
- self.glade.get_widget('delete_copy_torrent_toggle').set_active(True)
+ self.builder.get_object('delete_copy_torrent_toggle').set_active(True)
if not options:
client.core.get_config().addCallback(on_core_config)
@@ -184,33 +184,33 @@ class OptionsDialog(object):
)
if account['username'] == owner:
selected_iter = acc_iter
- self.glade.get_widget('OwnerCombobox').set_active_iter(selected_iter)
+ self.builder.get_object('OwnerCombobox').set_active_iter(selected_iter)
def on_accounts_failure(failure):
log.debug('Failed to get accounts!!! %s', failure)
acc_iter = self.accounts.append()
self.accounts.set_value(acc_iter, 0, client.get_auth_user())
- self.glade.get_widget('OwnerCombobox').set_active(0)
- self.glade.get_widget('OwnerCombobox').set_sensitive(False)
+ self.builder.get_object('OwnerCombobox').set_active(0)
+ self.builder.get_object('OwnerCombobox').set_sensitive(False)
def on_labels(labels):
log.debug('Got Labels: %s', labels)
for label in labels:
self.labels.set_value(self.labels.append(), 0, label)
- label_widget = self.glade.get_widget('label')
+ label_widget = self.builder.get_object('label')
label_widget.set_model(self.labels)
- label_widget.set_text_column(0)
+ label_widget.set_entry_text_column(0)
def on_failure(failure):
log.exception(failure)
def on_get_enabled_plugins(result):
if 'Label' in result:
- self.glade.get_widget('label_frame').show()
+ self.builder.get_object('label_frame').show()
client.label.get_labels().addCallback(on_labels).addErrback(on_failure)
else:
- self.glade.get_widget('label_frame').hide()
- self.glade.get_widget('label_toggle').set_active(False)
+ self.builder.get_object('label_frame').hide()
+ self.builder.get_object('label_toggle').set_active(False)
client.core.get_enabled_plugins().addCallback(on_get_enabled_plugins)
if client.get_auth_level() == deluge.common.AUTH_LEVEL_ADMIN:
@@ -220,8 +220,8 @@ class OptionsDialog(object):
else:
acc_iter = self.accounts.append()
self.accounts.set_value(acc_iter, 0, client.get_auth_user())
- self.glade.get_widget('OwnerCombobox').set_active(0)
- self.glade.get_widget('OwnerCombobox').set_sensitive(False)
+ self.builder.get_object('OwnerCombobox').set_active(0)
+ self.builder.get_object('OwnerCombobox').set_sensitive(False)
def set_sensitive(self):
maintoggles = ['download_location', 'append_extension',
@@ -230,49 +230,49 @@ class OptionsDialog(object):
'max_upload_slots', 'add_paused', 'auto_managed',
'stop_at_ratio', 'queue_to_top', 'copy_torrent']
for maintoggle in maintoggles:
- self.on_toggle_toggled(self.glade.get_widget(maintoggle + '_toggle'))
+ self.on_toggle_toggled(self.builder.get_object(maintoggle + '_toggle'))
def on_toggle_toggled(self, tb):
toggle = str(tb.name).replace('_toggle', '')
isactive = tb.get_active()
if toggle == 'download_location':
- self.glade.get_widget('download_location_chooser').set_sensitive(isactive)
- self.glade.get_widget('download_location_entry').set_sensitive(isactive)
+ self.builder.get_object('download_location_chooser').set_sensitive(isactive)
+ self.builder.get_object('download_location_entry').set_sensitive(isactive)
elif toggle == 'append_extension':
- self.glade.get_widget('append_extension').set_sensitive(isactive)
+ self.builder.get_object('append_extension').set_sensitive(isactive)
elif toggle == 'copy_torrent':
- self.glade.get_widget('copy_torrent_entry').set_sensitive(isactive)
- self.glade.get_widget('copy_torrent_chooser').set_sensitive(isactive)
- self.glade.get_widget('delete_copy_torrent_toggle').set_sensitive(isactive)
+ self.builder.get_object('copy_torrent_entry').set_sensitive(isactive)
+ self.builder.get_object('copy_torrent_chooser').set_sensitive(isactive)
+ self.builder.get_object('delete_copy_torrent_toggle').set_sensitive(isactive)
elif toggle == 'move_completed':
- self.glade.get_widget('move_completed_path_chooser').set_sensitive(isactive)
- self.glade.get_widget('move_completed_path_entry').set_sensitive(isactive)
- self.glade.get_widget('move_completed').set_active(isactive)
+ self.builder.get_object('move_completed_path_chooser').set_sensitive(isactive)
+ self.builder.get_object('move_completed_path_entry').set_sensitive(isactive)
+ self.builder.get_object('move_completed').set_active(isactive)
elif toggle == 'label':
- self.glade.get_widget('label').set_sensitive(isactive)
+ self.builder.get_object('label').set_sensitive(isactive)
elif toggle == 'max_download_speed':
- self.glade.get_widget('max_download_speed').set_sensitive(isactive)
+ self.builder.get_object('max_download_speed').set_sensitive(isactive)
elif toggle == 'max_upload_speed':
- self.glade.get_widget('max_upload_speed').set_sensitive(isactive)
+ self.builder.get_object('max_upload_speed').set_sensitive(isactive)
elif toggle == 'max_connections':
- self.glade.get_widget('max_connections').set_sensitive(isactive)
+ self.builder.get_object('max_connections').set_sensitive(isactive)
elif toggle == 'max_upload_slots':
- self.glade.get_widget('max_upload_slots').set_sensitive(isactive)
+ self.builder.get_object('max_upload_slots').set_sensitive(isactive)
elif toggle == 'add_paused':
- self.glade.get_widget('add_paused').set_sensitive(isactive)
- self.glade.get_widget('isnt_add_paused').set_sensitive(isactive)
+ self.builder.get_object('add_paused').set_sensitive(isactive)
+ self.builder.get_object('isnt_add_paused').set_sensitive(isactive)
elif toggle == 'queue_to_top':
- self.glade.get_widget('queue_to_top').set_sensitive(isactive)
- self.glade.get_widget('isnt_queue_to_top').set_sensitive(isactive)
+ self.builder.get_object('queue_to_top').set_sensitive(isactive)
+ self.builder.get_object('isnt_queue_to_top').set_sensitive(isactive)
elif toggle == 'auto_managed':
- self.glade.get_widget('auto_managed').set_sensitive(isactive)
- self.glade.get_widget('isnt_auto_managed').set_sensitive(isactive)
+ self.builder.get_object('auto_managed').set_sensitive(isactive)
+ self.builder.get_object('isnt_auto_managed').set_sensitive(isactive)
elif toggle == 'stop_at_ratio':
- self.glade.get_widget('remove_at_ratio_toggle').set_active(isactive)
- self.glade.get_widget('stop_ratio_toggle').set_active(isactive)
- self.glade.get_widget('stop_at_ratio').set_active(isactive)
- self.glade.get_widget('stop_ratio').set_sensitive(isactive)
- self.glade.get_widget('remove_at_ratio').set_sensitive(isactive)
+ self.builder.get_object('remove_at_ratio_toggle').set_active(isactive)
+ self.builder.get_object('stop_ratio_toggle').set_active(isactive)
+ self.builder.get_object('stop_at_ratio').set_active(isactive)
+ self.builder.get_object('stop_ratio').set_sensitive(isactive)
+ self.builder.get_object('remove_at_ratio').set_sensitive(isactive)
def on_apply(self, event=None):
try:
@@ -304,43 +304,43 @@ class OptionsDialog(object):
def generate_opts(self):
# generate options dict based on gtk objects
options = {}
- options['enabled'] = self.glade.get_widget('enabled').get_active()
+ options['enabled'] = self.builder.get_object('enabled').get_active()
if client.is_localhost():
- options['path'] = self.glade.get_widget('path_chooser').get_filename()
- options['download_location'] = self.glade.get_widget(
+ options['path'] = self.builder.get_object('path_chooser').get_filename()
+ options['download_location'] = self.builder.get_object(
'download_location_chooser').get_filename()
- options['move_completed_path'] = self.glade.get_widget(
+ options['move_completed_path'] = self.builder.get_object(
'move_completed_path_chooser').get_filename()
- options['copy_torrent'] = self.glade.get_widget(
+ options['copy_torrent'] = self.builder.get_object(
'copy_torrent_chooser').get_filename()
else:
- options['path'] = self.glade.get_widget('path_entry').get_text()
- options['download_location'] = self.glade.get_widget(
+ options['path'] = self.builder.get_object('path_entry').get_text()
+ options['download_location'] = self.builder.get_object(
'download_location_entry').get_text()
- options['move_completed_path'] = self.glade.get_widget(
+ options['move_completed_path'] = self.builder.get_object(
'move_completed_path_entry').get_text()
- options['copy_torrent'] = self.glade.get_widget(
+ options['copy_torrent'] = self.builder.get_object(
'copy_torrent_entry').get_text()
- options['label'] = self.glade.get_widget('label').child.get_text().lower()
- options['append_extension'] = self.glade.get_widget('append_extension').get_text()
+ options['label'] = self.builder.get_object('label').child.get_text().lower()
+ options['append_extension'] = self.builder.get_object('append_extension').get_text()
options['owner'] = self.accounts[
- self.glade.get_widget('OwnerCombobox').get_active()][0]
+ self.builder.get_object('OwnerCombobox').get_active()][0]
for key in ['append_extension_toggle', 'download_location_toggle',
'label_toggle', 'copy_torrent_toggle',
'delete_copy_torrent_toggle', 'seed_mode']:
- options[key] = self.glade.get_widget(key).get_active()
+ options[key] = self.builder.get_object(key).get_active()
for spin_id in self.spin_ids:
- options[spin_id] = self.glade.get_widget(spin_id).get_value()
- options[spin_id + '_toggle'] = self.glade.get_widget(spin_id + '_toggle').get_active()
+ options[spin_id] = self.builder.get_object(spin_id).get_value()
+ options[spin_id + '_toggle'] = self.builder.get_object(spin_id + '_toggle').get_active()
for spin_int_id in self.spin_int_ids:
- options[spin_int_id] = self.glade.get_widget(spin_int_id).get_value_as_int()
- options[spin_int_id + '_toggle'] = self.glade.get_widget(spin_int_id + '_toggle').get_active()
+ options[spin_int_id] = self.builder.get_object(spin_int_id).get_value_as_int()
+ options[spin_int_id + '_toggle'] = self.builder.get_object(spin_int_id + '_toggle').get_active()
for chk_id in self.chk_ids:
- options[chk_id] = self.glade.get_widget(chk_id).get_active()
- options[chk_id + '_toggle'] = self.glade.get_widget(chk_id + '_toggle').get_active()
+ options[chk_id] = self.builder.get_object(chk_id).get_active()
+ options[chk_id + '_toggle'] = self.builder.get_object(chk_id + '_toggle').get_active()
if options['copy_torrent_toggle'] and options['path'] == options['copy_torrent']:
raise IncompatibleOption(_('"Watch Folder" directory and "Copy of .torrent'
@@ -351,12 +351,9 @@ class OptionsDialog(object):
class GtkUI(GtkPluginBase):
def enable(self):
- self.glade = gtk.glade.XML(get_resource('config.glade'))
- self.glade.signal_autoconnect({
- 'on_add_button_clicked': self.on_add_button_clicked,
- 'on_edit_button_clicked': self.on_edit_button_clicked,
- 'on_remove_button_clicked': self.on_remove_button_clicked
- })
+ self.builder = gtk.Builder()
+ self.builder.add_from_file(get_resource('config.ui'))
+ self.builder.connect_signals(self)
self.opts_dialog = OptionsDialog()
component.get('PluginManager').register_hook(
@@ -371,7 +368,7 @@ class GtkUI(GtkPluginBase):
self.watchdirs = {}
- vbox = self.glade.get_widget('watchdirs_vbox')
+ vbox = self.builder.get_object('watchdirs_vbox')
sw = gtk.ScrolledWindow()
sw.set_shadow_type(gtk.SHADOW_ETCHED_IN)
sw.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)
@@ -389,7 +386,7 @@ class GtkUI(GtkPluginBase):
sw.add(self.treeView)
sw.show_all()
component.get('Preferences').add_page(
- _('AutoAdd'), self.glade.get_widget('prefs_box')
+ _('AutoAdd'), self.builder.get_object('prefs_box')
)
def disable(self):
@@ -468,11 +465,11 @@ class GtkUI(GtkPluginBase):
def on_listitem_activated(self, treeview):
tree, tree_id = self.treeView.get_selection().get_selected()
if tree_id:
- self.glade.get_widget('edit_button').set_sensitive(True)
- self.glade.get_widget('remove_button').set_sensitive(True)
+ self.builder.get_object('edit_button').set_sensitive(True)
+ self.builder.get_object('remove_button').set_sensitive(True)
else:
- self.glade.get_widget('edit_button').set_sensitive(False)
- self.glade.get_widget('remove_button').set_sensitive(False)
+ self.builder.get_object('edit_button').set_sensitive(False)
+ self.builder.get_object('remove_button').set_sensitive(False)
def on_apply_prefs(self):
log.debug('applying prefs for AutoAdd')
@@ -496,7 +493,7 @@ class GtkUI(GtkPluginBase):
watchdir.get('owner', 'localclient'), watchdir['path']
])
# Workaround for cached glade signal appearing when re-enabling plugin in same session
- if self.glade.get_widget('edit_button'):
+ if self.builder.get_object('edit_button'):
# Disable the remove and edit buttons, because nothing in the store is selected
- self.glade.get_widget('remove_button').set_sensitive(False)
- self.glade.get_widget('edit_button').set_sensitive(False)
+ self.builder.get_object('remove_button').set_sensitive(False)
+ self.builder.get_object('edit_button').set_sensitive(False)