Author: duncan
Date: Mon Sep 25 12:34:54 2006
New Revision: 8236

Modified:
   branches/rel-1-5/freevo/src/video/configure.py
   branches/rel-1-5/freevo/src/video/plugins/mplayer.py

Log:
[ 1402649 ] Audio language setting broken with MPlayer for DVD playback
The audio id was not correctly set, fixed this in mmpython
Changed display of languages to the full name if it exists


Modified: branches/rel-1-5/freevo/src/video/configure.py
==============================================================================
--- branches/rel-1-5/freevo/src/video/configure.py      (original)
+++ branches/rel-1-5/freevo/src/video/configure.py      Mon Sep 25 12:34:54 2006
@@ -81,13 +81,18 @@
         if not a.has_key('id') or a['id'] in ('', None):
             a['id'] = item.info['audio'].index(a) + 1
         
-        if not a.has_key('language') or not a['language']:
+        if a.has_key('languagedesc') and a['languagedesc']:
+            a['language'] = a['languagedesc']
+        elif not a.has_key('language') or not a['language']:
             a['language'] = _('Stream %s') % a['id']
 
         if not a.has_key('channels') or not a['channels']:
             a['channels'] = 2 # wild guess :-)
 
-        txt = '%s (channels=%s)' % (a['language'], a['channels'])
+        if not a.has_key('codec') or not a['codec']:
+            a['codec'] = '???'
+
+        txt = '%s (channels=%s:%s)' % (a['language'], a['channels'], 
a['codec'])
         menu_items.append(menu.MenuItem(txt, audio_selection, (item, a['id'])))
 
     moviemenu = menu.Menu(_('Audio Menu'), menu_items, fxd_file=item.skin_fxd)

Modified: branches/rel-1-5/freevo/src/video/plugins/mplayer.py
==============================================================================
--- branches/rel-1-5/freevo/src/video/plugins/mplayer.py        (original)
+++ branches/rel-1-5/freevo/src/video/plugins/mplayer.py        Mon Sep 25 
12:34:54 2006
@@ -245,14 +245,16 @@
         if item.selected_subtitle == -1:
             additional_args += [ '-noautosub' ]
 
-        elif item.selected_subtitle and mode == 'file':
-            if os.path.isfile(os.path.splitext(item.filename)[0]+'.idx'):
+        elif item.selected_subtitle:
+            if mode == 'file':
+                if os.path.isfile(os.path.splitext(item.filename)[0]+'.idx'):
+                    additional_args += [ '-vobsubid', 
str(item.selected_subtitle) ]
+                else:
+                    additional_args += [ '-sid', str(item.selected_subtitle) ]
+            elif mode == 'dvd':
                 additional_args += [ '-vobsubid', str(item.selected_subtitle) ]
             else:
                 additional_args += [ '-sid', str(item.selected_subtitle) ]
-                
-        elif item.selected_subtitle:
-            additional_args += [ '-sid', str(item.selected_subtitle) ]
             
         if item.selected_audio != None:
             additional_args += [ '-aid', str(item.selected_audio) ]

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Freevo-cvslog mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to