[vlc-devel] [PATCH 3/3] qt: provide translation for filters in logo file selector

Pierre Lamot pierre at videolabs.io
Wed Nov 29 10:22:06 CET 2017


---
 modules/gui/qt/components/extended_panels.cpp | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/modules/gui/qt/components/extended_panels.cpp b/modules/gui/qt/components/extended_panels.cpp
index 88f46d50a5..fd82a43fe1 100644
--- a/modules/gui/qt/components/extended_panels.cpp
+++ b/modules/gui/qt/components/extended_panels.cpp
@@ -51,6 +51,7 @@
 #include "input_manager.hpp"
 #include "util/qt_dirs.hpp"
 #include "util/customwidgets.hpp"
+#include "dialogs_provider.hpp"
 
 #include "../../audio_filter/equalizer_presets.h"
 #include <vlc_vout.h>
@@ -357,16 +358,22 @@ void ExtVideo::updateFilters()
 
 void ExtVideo::browseLogo()
 {
+    QString filter = QString( "%1 (*.png *.jpg);;%2 (*)" )
+                        .arg( qtr("Image Files") )
+                        .arg( TITLE_EXTENSIONS_ALL );
     QString file = QFileDialog::getOpenFileName( NULL, qtr( "Logo filenames" ),
-                   p_intf->p_sys->filepath, "Images (*.png *.jpg);;All (*)" );
+                   p_intf->p_sys->filepath, filter );
 
     UPDATE_AND_APPLY_TEXT( logoFileText, file );
 }
 
 void ExtVideo::browseEraseFile()
 {
+    QString filter = QString( "%1 (*.png *.jpg);;%2 (*)" )
+                        .arg( qtr("Image Files") )
+                        .arg( TITLE_EXTENSIONS_ALL );
     QString file = QFileDialog::getOpenFileName( NULL, qtr( "Image mask" ),
-                   p_intf->p_sys->filepath, "Images (*.png *.jpg);;All (*)" );
+                   p_intf->p_sys->filepath, filter );
 
     UPDATE_AND_APPLY_TEXT( eraseMaskText, file );
 }
-- 
2.14.1



More information about the vlc-devel mailing list