Author: duncan
Date: Mon Jan 28 13:29:10 2008
New Revision: 10312

Log:
Added TV_CHANNELS_COMPARE for more flexible compare of chennels


Modified:
   branches/rel-1/freevo/freevo_config.py
   branches/rel-1/freevo/local_conf.py.example
   branches/rel-1/freevo/src/config.py

Modified: branches/rel-1/freevo/freevo_config.py
==============================================================================
--- branches/rel-1/freevo/freevo_config.py      (original)
+++ branches/rel-1/freevo/freevo_config.py      Mon Jan 28 13:29:10 2008
@@ -344,6 +344,7 @@
      '''Added RECORDSERVER_SECRET and RECORDSERVER_PORT2=18002 for kaa.rpc
      Renamed audio plug-in audio.playlist to audio.playlists
      Added ENCODINGSERVER_SAVE_DIR for re-encoded DVDs
+     Added TV_CHANNELS_COMPARE as a lambda to sort the channels
      '''),
 ]
 
@@ -1915,6 +1916,11 @@
 
 TV_CHANNELS = None
 
+#
+# A lambda function to sort the TV_CHANNELS
+#
+TV_CHANNELS_COMPARE = lambda a, b: cmp(int(a[2]), int(b[2]))
+
 
 # Program to grab xmltv listings. To get a grabber, you need to download
 # xmltv. A possible value for users in the USA is tv_grab_na

Modified: branches/rel-1/freevo/local_conf.py.example
==============================================================================
--- branches/rel-1/freevo/local_conf.py.example (original)
+++ branches/rel-1/freevo/local_conf.py.example Mon Jan 28 13:29:10 2008
@@ -1505,6 +1505,11 @@
 # TV_CHANNELS = None
 
 #
+# A lambda function to sort the TV_CHANNELS
+#
+#TV_CHANNELS_COMPARE = lambda a, b: cmp(int(a[2]), int(b[2]))
+
+#
 # TV_FREQUENCY_TABLE - This is only used when Freevo changes the channel 
natively.
 # This is only the case if you are using V4L2 and any of the following plugins:
 # timeshift, ivtv_record, ivtv_basic_tv.

Modified: branches/rel-1/freevo/src/config.py
==============================================================================
--- branches/rel-1/freevo/src/config.py (original)
+++ branches/rel-1/freevo/src/config.py Mon Jan 28 13:29:10 2008
@@ -967,7 +967,7 @@
 
             chanlist += [(id, display_name, tunerid)]
 
-        f = lambda a, b: cmp(int(a[2]), int(b[2]))
+        f = config.TV_CHANNELS_COMPARE
         chanlist.sort(f)
 
         try:

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to