]> git.sesse.net Git - vlc/commitdiff
* build the subtitle align combo box
authorYoann Peronneau <yoann@videolan.org>
Mon, 26 Mar 2007 23:23:28 +0000 (23:23 +0000)
committerYoann Peronneau <yoann@videolan.org>
Mon, 26 Mar 2007 23:23:28 +0000 (23:23 +0000)
modules/gui/qt4/components/open.cpp
modules/gui/qt4/ui/open_file.ui

index 426894ba2263d288cf3f27a8ffc23445221597d3..10e35393d5b37247d711564ba155eb68d14b9a78 100644 (file)
@@ -106,6 +106,22 @@ FileOpenPanel::FileOpenPanel( QWidget *_parent, intf_thread_t *_p_intf ) :
         }
     }
 
+    /* Build the subs align combo box */
+    p_item = config_FindConfig( VLC_OBJECT(p_intf), "subsdec-align" );
+    if( p_item )
+    {
+        for( int i_index = 0; i_index < p_item->i_list; i_index++ )
+        {
+            ui.alignSubComboBox->addItem(
+                qfu( p_item->ppsz_list_text[i_index] ),
+                QVariant( p_item->pi_list[i_index] ) );
+            if( p_item->value.i == p_item->pi_list[i_index] )
+            {
+                ui.alignSubComboBox->setCurrentIndex( i_index );
+            }
+        }
+    }
+
     BUTTONACT( ui.subBrowseButton, browseFileSub() );
     BUTTONACT( ui.subCheckBox, toggleSubtitleFrame());
 
index c9c76d11de02614a8429b98e2fb399d7517c6f21..eb71c57b90fe953b912cc3d746cda98ff25ac782 100644 (file)
         <property name="minimumContentsLength" >
          <number>0</number>
         </property>
-        <item>
-         <property name="text" >
-          <string>Left</string>
-         </property>
-        </item>
-        <item>
-         <property name="text" >
-          <string>Center</string>
-         </property>
-        </item>
-        <item>
-         <property name="text" >
-          <string>Right</string>
-         </property>
-        </item>
        </widget>
       </item>
       <item row="1" column="4" >