[gpodder-devel] Feature request (synchronize only unplayed podcasts)

  • From: stephan.buys at gmail.com (Stephan Buys)
  • Date: Wed, 18 Apr 2007 10:13:45 +0200

Here is my patch to enable this functionality, it needs interface
elements...

Index: src/gpodder/libpodcasts.py
===================================================================
--- src/gpodder/libpodcasts.py  (revision 313)
+++ src/gpodder/libpodcasts.py  (working copy)
@@ -223,6 +223,9 @@
     def is_downloaded( self, item):
         return self.podcastFilenameExists( item.url)

+    def is_played(self, item):
+       return libgpodder.gPodderLib().history_is_played( item.url)
+
     def get_all_episodes( self):
         episodes = []
         added_urls = []
Index: src/gpodder/libipodsync.py
===================================================================
--- src/gpodder/libipodsync.py  (revision 313)
+++ src/gpodder/libipodsync.py  (working copy)
@@ -165,7 +165,7 @@
             if self.cancelled:
                 return False
             self.set_progress( pos, max)
-            if channel.is_downloaded( episode):
+            if channel.is_downloaded( episode) and not channel.is_played(
episode):
                 self.add_episode_from_channel( channel, episode)
             pos = pos + 1
         self.set_progress( pos, max)



On 4/11/07, Thomas Perl <thp at perli.net> wrote:
>
> Hello, Stephan!
>
> On Tue, 2007-04-10 at 08:01 +0200, Stephan Buys wrote:
> > It would be great if gpodder supported (either through preferences or
> > through an addition to the device list) the ability to synchronize
> > only unplayed podcasts or the last "x" number of unplayed podcasts.
> > This is a feature that is currently supported by iTunes and would be
> > of great help for persons with limited free space on their devices or
> > massive podcast collections.
>
> I've added it to the TODO list. Patches (as always) welcome.
>
>
> Enjoy,
> homas
>
>
> _______________________________________________
> gpodder-devel mailing list
> gpodder-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/gpodder-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<https://lists.berlios.de/pipermail/gpodder-devel/attachments/20070418/596fabdd/attachment.html>

Other related posts: