menu re-structured

git-svn-id: svn://svn.berlios.de/gpodder/trunk@218 b0d088ad-0a06-0410-aad2-9ed5178a7e87
This commit is contained in:
Thomas Perl 2006-12-16 17:44:13 +00:00
parent b601aea522
commit ebf8a8924a
5 changed files with 226 additions and 179 deletions

View File

@ -1,3 +1,9 @@
Sat, 16 Dec 2006 18:43:04 +0100 <thp@perli.net>
* data/gpodder.glade: Re-structured the main menu
* src/gpodder/gpodder.py: Added some code to make the main menu
appear more dynamic and context-specific
* bin/gpodder: The usual: push version + date
Wed, 13 Dec 2006 13:57:54 +0100 <thp@perli.net>
* src/gpodder/libwget.py: Make wget "continue" (-c) and "retry
infinite" (-t0) so we don't get strange results when server

View File

@ -26,8 +26,8 @@
# PLEASE DO NOT CHANGE FORMAT OF __version__ LINE (setup.py reads this)
__author__ = "Thomas Perl <thp@perli.net>"
__version__ = "0.8.0+svn20061212"
__date__ = "2006-12-12"
__version__ = "0.8.0+svn20061216"
__date__ = "2006-12-16"
__copyright__ = "Copyright (c) 2005-2006 %s. All rights reserved." % __author__
__licence__ = "GPL"

View File

@ -42,7 +42,7 @@
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image1392">
<widget class="GtkImage" id="image2206">
<property name="visible">True</property>
<property name="stock">gtk-cdrom</property>
<property name="icon_size">1</property>
@ -62,9 +62,10 @@
<property name="label" translatable="yes">_Check for Updates</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemUpdate_activate" last_modification_time="Sat, 29 Oct 2005 11:28:10 GMT"/>
<accelerator key="R" modifiers="GDK_CONTROL_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1393">
<widget class="GtkImage" id="image2207">
<property name="visible">True</property>
<property name="stock">gtk-refresh</property>
<property name="icon_size">1</property>
@ -84,16 +85,16 @@
</child>
<child>
<widget class="GtkImageMenuItem" id="sync_to_ipod">
<widget class="GtkImageMenuItem" id="itemAddChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Sync to device</property>
<property name="label" translatable="yes">_Subscribe to new channel</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_sync_to_ipod_activate" last_modification_time="Wed, 05 Apr 2006 21:49:38 GMT"/>
<signal name="activate" handler="on_itemAddChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:33:59 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1394">
<widget class="GtkImage" id="image2208">
<property name="visible">True</property>
<property name="stock">gtk-save</property>
<property name="stock">gtk-add</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
@ -105,16 +106,16 @@
</child>
<child>
<widget class="GtkImageMenuItem" id="cleanup_ipod">
<widget class="GtkImageMenuItem" id="itemEditChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Cleanup device</property>
<property name="label" translatable="yes">_Edit channel</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_cleanup_ipod_activate" last_modification_time="Wed, 05 Apr 2006 22:14:51 GMT"/>
<signal name="activate" handler="on_itemEditChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:34:38 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1395">
<widget class="GtkImage" id="image2209">
<property name="visible">True</property>
<property name="stock">gtk-delete</property>
<property name="stock">gtk-edit</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
@ -125,6 +126,168 @@
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemRemoveChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Remove channel</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemRemoveChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:35:16 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image2210">
<property name="visible">True</property>
<property name="stock">gtk-remove</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkSeparatorMenuItem" id="separator7">
<property name="visible">True</property>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemDevice">
<property name="visible">True</property>
<property name="label" translatable="yes">Device</property>
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image2211">
<property name="visible">True</property>
<property name="stock">gtk-connect</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
<child>
<widget class="GtkMenu" id="itemDevice_menu">
<child>
<widget class="GtkImageMenuItem" id="sync_to_ipod">
<property name="visible">True</property>
<property name="label" translatable="yes">_Synchronize</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_sync_to_ipod_activate" last_modification_time="Wed, 05 Apr 2006 21:49:38 GMT"/>
<accelerator key="S" modifiers="GDK_CONTROL_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image2212">
<property name="visible">True</property>
<property name="stock">gtk-refresh</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="cleanup_ipod">
<property name="visible">True</property>
<property name="label" translatable="yes">_Remove podcasts</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_cleanup_ipod_activate" last_modification_time="Wed, 05 Apr 2006 22:14:51 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image2213">
<property name="visible">True</property>
<property name="stock">gtk-delete</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="advanced1">
<property name="visible">True</property>
<property name="label" translatable="yes">Channel _list</property>
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image2214">
<property name="visible">True</property>
<property name="stock">gtk-justify-left</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
<child>
<widget class="GtkMenu" id="advanced1_menu">
<child>
<widget class="GtkImageMenuItem" id="itemExportChannels">
<property name="visible">True</property>
<property name="label" translatable="yes">E_xport to OPML</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemExportChannels_activate" last_modification_time="Sat, 29 Oct 2005 11:37:45 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image2215">
<property name="visible">True</property>
<property name="stock">gtk-save-as</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemImportChannels">
<property name="visible">True</property>
<property name="label" translatable="yes">_Import from web</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemImportChannels_activate" last_modification_time="Tue, 13 Jun 2006 19:39:42 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image2216">
<property name="visible">True</property>
<property name="stock">gtk-redo</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkSeparatorMenuItem" id="trennlinie2">
<property name="visible">True</property>
@ -137,9 +300,10 @@
<property name="label" translatable="yes">_Preferences...</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemPreferences_activate" last_modification_time="Sat, 29 Oct 2005 11:29:01 GMT"/>
<accelerator key="P" modifiers="GDK_CONTROL_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1396">
<widget class="GtkImage" id="image2217">
<property name="visible">True</property>
<property name="stock">gtk-preferences</property>
<property name="icon_size">1</property>
@ -164,9 +328,10 @@
<property name="label" translatable="yes">_Close</property>
<property name="use_underline">True</property>
<signal name="activate" handler="close_gpodder" last_modification_time="Sat, 29 Oct 2005 11:54:31 GMT"/>
<accelerator key="Q" modifiers="GDK_CONTROL_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1397">
<widget class="GtkImage" id="image2218">
<property name="visible">True</property>
<property name="stock">gtk-quit</property>
<property name="icon_size">1</property>
@ -190,7 +355,7 @@
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image1398">
<widget class="GtkImage" id="image2219">
<property name="visible">True</property>
<property name="stock">gtk-justify-left</property>
<property name="icon_size">1</property>
@ -204,151 +369,16 @@
<child>
<widget class="GtkMenu" id="menuChannels_menu">
<child>
<widget class="GtkImageMenuItem" id="itemAddChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Add channel...</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemAddChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:33:59 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1399">
<property name="visible">True</property>
<property name="stock">gtk-open</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemEditChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Edit channel...</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemEditChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:34:38 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1400">
<property name="visible">True</property>
<property name="stock">gtk-edit</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemRemoveChannel">
<property name="visible">True</property>
<property name="label" translatable="yes">_Remove channel</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemRemoveChannel_activate" last_modification_time="Sat, 29 Oct 2005 11:35:16 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1401">
<property name="visible">True</property>
<property name="stock">gtk-delete</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkSeparatorMenuItem" id="trennlinie7">
<property name="visible">True</property>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemExportChannels">
<property name="visible">True</property>
<property name="label" translatable="yes">E_xport list...</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemExportChannels_activate" last_modification_time="Sat, 29 Oct 2005 11:37:45 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1402">
<property name="visible">True</property>
<property name="stock">gtk-save-as</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="itemImportChannels">
<property name="visible">True</property>
<property name="label" translatable="yes">_Import from web</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_itemImportChannels_activate" last_modification_time="Tue, 13 Jun 2006 19:39:42 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1403">
<property name="visible">True</property>
<property name="stock">gtk-redo</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
</widget>
</child>
</widget>
</child>
</widget>
</child>
<child>
<widget class="GtkImageMenuItem" id="menuEpisode">
<property name="visible">True</property>
<property name="label" translatable="yes">_Episode</property>
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image1404">
<property name="visible">True</property>
<property name="stock">gtk-go-down</property>
<property name="icon_size">1</property>
<property name="xalign">0.5</property>
<property name="yalign">0.5</property>
<property name="xpad">0</property>
<property name="ypad">0</property>
</widget>
</child>
<child>
<widget class="GtkMenu" id="menuEpisode_menu">
<child>
<widget class="GtkImageMenuItem" id="itemDownloadNew">
<property name="visible">True</property>
<property name="label" translatable="yes">Download new episodes</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_btnDownloadNewer_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<accelerator key="N" modifiers="GDK_CONTROL_MASK | GDK_MOD1_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1405">
<widget class="GtkImage" id="image2220">
<property name="visible">True</property>
<property name="stock">gtk-about</property>
<property name="icon_size">1</property>
@ -369,7 +399,7 @@
<signal name="activate" handler="on_btnSelectAllAvailable_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1406">
<widget class="GtkImage" id="image2221">
<property name="visible">True</property>
<property name="stock">gtk-sort-ascending</property>
<property name="icon_size">1</property>
@ -390,7 +420,7 @@
<signal name="activate" handler="on_btnDownload_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1407">
<widget class="GtkImage" id="image2222">
<property name="visible">True</property>
<property name="stock">gtk-goto-bottom</property>
<property name="icon_size">1</property>
@ -415,9 +445,10 @@
<property name="label" translatable="yes">Delete all episodes</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_btnDeleteAll_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<accelerator key="Delete" modifiers="GDK_CONTROL_MASK" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1408">
<widget class="GtkImage" id="image2223">
<property name="visible">True</property>
<property name="stock">gtk-clear</property>
<property name="icon_size">1</property>
@ -436,9 +467,10 @@
<property name="label" translatable="yes">Delete selected episodes</property>
<property name="use_underline">True</property>
<signal name="activate" handler="on_btnDownloadedDelete_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<accelerator key="Delete" modifiers="0" signal="activate"/>
<child internal-child="image">
<widget class="GtkImage" id="image1409">
<widget class="GtkImage" id="image2224">
<property name="visible">True</property>
<property name="stock">gtk-delete</property>
<property name="icon_size">1</property>
@ -459,7 +491,7 @@
<signal name="activate" handler="on_btnDownloadedExecute_clicked" last_modification_time="Fri, 08 Dec 2006 23:50:54 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1410">
<widget class="GtkImage" id="image2225">
<property name="visible">True</property>
<property name="stock">gtk-media-play</property>
<property name="icon_size">1</property>
@ -483,7 +515,7 @@
<property name="use_underline">True</property>
<child internal-child="image">
<widget class="GtkImage" id="image1411">
<widget class="GtkImage" id="image2226">
<property name="visible">True</property>
<property name="stock">gtk-help</property>
<property name="icon_size">1</property>
@ -505,7 +537,7 @@
<signal name="activate" handler="on_homepage_activate" last_modification_time="Mon, 04 Dec 2006 12:08:55 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1412">
<widget class="GtkImage" id="image2227">
<property name="visible">True</property>
<property name="stock">gtk-home</property>
<property name="icon_size">1</property>
@ -532,7 +564,7 @@
<signal name="activate" handler="on_wishlist_activate" last_modification_time="Mon, 04 Dec 2006 12:06:32 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1413">
<widget class="GtkImage" id="image2228">
<property name="visible">True</property>
<property name="stock">gtk-edit</property>
<property name="icon_size">1</property>
@ -553,7 +585,7 @@
<signal name="activate" handler="on_mailinglist_activate" last_modification_time="Mon, 04 Dec 2006 12:12:24 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1414">
<widget class="GtkImage" id="image2229">
<property name="visible">True</property>
<property name="stock">gtk-find</property>
<property name="icon_size">1</property>
@ -580,7 +612,7 @@
<signal name="activate" handler="on_itemAbout_activate" last_modification_time="Sat, 29 Oct 2005 11:40:19 GMT"/>
<child internal-child="image">
<widget class="GtkImage" id="image1415">
<widget class="GtkImage" id="image2230">
<property name="visible">True</property>
<property name="stock">gtk-about</property>
<property name="icon_size">1</property>

View File

@ -603,6 +603,15 @@ class Gpodder(SimpleGladeApp):
except:
self.active_channel = None
if self.active_channel:
self.itemEditChannel.get_child().set_text( _('Edit "%s"') % ( self.active_channel.title,))
self.itemRemoveChannel.get_child().set_text( _('Remove "%s"') % ( self.active_channel.title,))
self.itemEditChannel.show_all()
self.itemRemoveChannel.show_all()
else:
self.itemEditChannel.hide_all()
self.itemRemoveChannel.hide_all()
self.updateTreeView()
#-- Gpodder.on_comboAvailable_changed }

View File

@ -50,21 +50,6 @@ class Gpodder(SimpleGladeApp):
print "on_itemUpdate_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_itemUpdate_activate }
#-- Gpodder.on_sync_to_ipod_activate {
def on_sync_to_ipod_activate(self, widget, *args):
print "on_sync_to_ipod_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_sync_to_ipod_activate }
#-- Gpodder.on_cleanup_ipod_activate {
def on_cleanup_ipod_activate(self, widget, *args):
print "on_cleanup_ipod_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_cleanup_ipod_activate }
#-- Gpodder.on_itemPreferences_activate {
def on_itemPreferences_activate(self, widget, *args):
print "on_itemPreferences_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_itemPreferences_activate }
#-- Gpodder.on_itemAddChannel_activate {
def on_itemAddChannel_activate(self, widget, *args):
print "on_itemAddChannel_activate called with self.%s" % widget.get_name()
@ -80,6 +65,16 @@ class Gpodder(SimpleGladeApp):
print "on_itemRemoveChannel_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_itemRemoveChannel_activate }
#-- Gpodder.on_sync_to_ipod_activate {
def on_sync_to_ipod_activate(self, widget, *args):
print "on_sync_to_ipod_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_sync_to_ipod_activate }
#-- Gpodder.on_cleanup_ipod_activate {
def on_cleanup_ipod_activate(self, widget, *args):
print "on_cleanup_ipod_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_cleanup_ipod_activate }
#-- Gpodder.on_itemExportChannels_activate {
def on_itemExportChannels_activate(self, widget, *args):
print "on_itemExportChannels_activate called with self.%s" % widget.get_name()
@ -90,6 +85,11 @@ class Gpodder(SimpleGladeApp):
print "on_itemImportChannels_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_itemImportChannels_activate }
#-- Gpodder.on_itemPreferences_activate {
def on_itemPreferences_activate(self, widget, *args):
print "on_itemPreferences_activate called with self.%s" % widget.get_name()
#-- Gpodder.on_itemPreferences_activate }
#-- Gpodder.on_btnDownloadNewer_clicked {
def on_btnDownloadNewer_clicked(self, widget, *args):
print "on_btnDownloadNewer_clicked called with self.%s" % widget.get_name()