add "remove torrent" to right-click menu

This commit is contained in:
Marcos Pinto 2007-06-20 19:19:59 +00:00
parent 846058a8d0
commit 8a3c47eea2
3 changed files with 20 additions and 3 deletions

View File

@ -4,6 +4,22 @@
<glade-interface> <glade-interface>
<widget class="GtkMenu" id="torrent_menu"> <widget class="GtkMenu" id="torrent_menu">
<property name="visible">True</property> <property name="visible">True</property>
<child>
<widget class="GtkImageMenuItem" id="menuitem12">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<property name="label" translatable="yes">Remove Torrent</property>
<property name="use_underline">True</property>
<signal name="activate" handler="remove_torrent"/>
<child internal-child="image">
<widget class="GtkImage" id="menu-item-image9">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<property name="stock">gtk-remove</property>
</widget>
</child>
</widget>
</child>
<child> <child>
<widget class="GtkImageMenuItem" id="menu_pause"> <widget class="GtkImageMenuItem" id="menu_pause">
<property name="visible">True</property> <property name="visible">True</property>

View File

@ -144,8 +144,8 @@ if boosttype == "nomt":
'boost_thread', 'z', 'pthread', 'ssl'] 'boost_thread', 'z', 'pthread', 'ssl']
print 'Libraries nomt' print 'Libraries nomt'
elif boosttype == "mt": elif boosttype == "mt":
librariestype = ['boost_filesystem-mt', 'boost_date_time-mt', librariestype = ['boost_filesystem', 'boost_date_time',
'boost_thread-mt', 'z', 'pthread', 'ssl'] 'boost_thread', 'z', 'pthread', 'ssl']
print 'Libraries mt' print 'Libraries mt'
deluge_core = Extension('deluge_core', deluge_core = Extension('deluge_core',

View File

@ -292,7 +292,8 @@ class DelugeGTK:
self.torrent_view = self.wtree.get_widget("torrent_view") self.torrent_view = self.wtree.get_widget("torrent_view")
self.torrent_glade = gtk.glade.XML(common.get_glade_file("torrent_menu.glade"), domain='deluge') self.torrent_glade = gtk.glade.XML(common.get_glade_file("torrent_menu.glade"), domain='deluge')
self.torrent_menu = self.torrent_glade.get_widget("torrent_menu") self.torrent_menu = self.torrent_glade.get_widget("torrent_menu")
self.torrent_glade.signal_autoconnect({ "start_pause": self.start_pause, self.torrent_glade.signal_autoconnect({ "remove_torrent": self.remove_torrent_clicked,
"start_pause": self.start_pause,
"update_tracker": self.update_tracker, "update_tracker": self.update_tracker,
"clear_finished": self.clear_finished, "clear_finished": self.clear_finished,
"queue_up": self.q_torrent_up, "queue_up": self.q_torrent_up,