[vlc-commits] qt: remove forward declaration
Thomas Guillem
git at videolan.org
Wed May 31 17:45:14 CEST 2017
vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Wed May 24 09:56:50 2017 +0200| [09dc6e5c280627e2a0f700d447d7ca20160b850a] | committer: Thomas Guillem
qt: remove forward declaration
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=09dc6e5c280627e2a0f700d447d7ca20160b850a
---
modules/gui/qt/components/extended_panels.cpp | 50 ++++++++++++---------------
1 file changed, 23 insertions(+), 27 deletions(-)
diff --git a/modules/gui/qt/components/extended_panels.cpp b/modules/gui/qt/components/extended_panels.cpp
index 9080238393..d7673cc53b 100644
--- a/modules/gui/qt/components/extended_panels.cpp
+++ b/modules/gui/qt/components/extended_panels.cpp
@@ -53,9 +53,29 @@
#include <vlc_modules.h>
#include <vlc_plugin.h>
-static QString ChangeFiltersString( struct intf_thread_t *p_intf, const char *psz_filter_type, const char *psz_name, bool b_add );
-static void ChangeAFiltersString( struct intf_thread_t *p_intf, const char *psz_name, bool b_add );
-static void ChangeVFiltersString( struct intf_thread_t *p_intf, const char *psz_name, bool b_add );
+static const char* GetVFilterType( struct intf_thread_t *p_intf, const char *psz_name )
+{
+ module_t *p_obj = module_find( psz_name );
+ if( !p_obj )
+ {
+ msg_Err( p_intf, "Unable to find filter module \"%s\".", psz_name );
+ return NULL;
+ }
+
+ if( module_provides( p_obj, "video splitter" ) )
+ return "video-splitter";
+ else if( module_provides( p_obj, "video filter" ) )
+ return "video-filter";
+ else if( module_provides( p_obj, "sub source" ) )
+ return "sub-source";
+ else if( module_provides( p_obj, "sub filter" ) )
+ return "sub-filter";
+ else
+ {
+ msg_Err( p_intf, "Unknown video filter type." );
+ return NULL;
+ }
+}
static const QString ModuleFromWidgetName( QObject *obj )
{
@@ -277,30 +297,6 @@ static void ChangeAFiltersString( struct intf_thread_t *p_intf, const char *psz_
config_PutPsz( p_intf, "audio-filter", qtu( result ) );
}
-static const char* GetVFilterType( struct intf_thread_t *p_intf, const char *psz_name )
-{
- module_t *p_obj = module_find( psz_name );
- if( !p_obj )
- {
- msg_Err( p_intf, "Unable to find filter module \"%s\".", psz_name );
- return NULL;
- }
-
- if( module_provides( p_obj, "video splitter" ) )
- return "video-splitter";
- else if( module_provides( p_obj, "video filter" ) )
- return "video-filter";
- else if( module_provides( p_obj, "sub source" ) )
- return "sub-source";
- else if( module_provides( p_obj, "sub filter" ) )
- return "sub-filter";
- else
- {
- msg_Err( p_intf, "Unknown video filter type." );
- return NULL;
- }
-}
-
static void ChangeVFiltersString( struct intf_thread_t *p_intf, const char *psz_name, bool b_add )
{
const char *psz_filter_type = GetVFilterType( p_intf, psz_name );
More information about the vlc-commits
mailing list