mirror of
https://code.videolan.org/videolan/vlc
synced 2024-09-04 09:11:33 +02:00
Fix a bug with preferences
Added some more names Use shortname to store the name
This commit is contained in:
parent
798c883b4d
commit
906b68fe03
@ -84,7 +84,6 @@ struct module_t
|
||||
* Variables set by the module to identify itself
|
||||
*/
|
||||
char *psz_shortname; /* Module name */
|
||||
char *psz_name; /* Human-readable shortname */
|
||||
char *psz_longname; /* Module descriptive name */
|
||||
|
||||
/*
|
||||
|
@ -99,8 +99,7 @@
|
||||
p_module->b_unloadable = VLC_TRUE; \
|
||||
p_module->b_reentrant = VLC_TRUE; \
|
||||
p_module->psz_object_name = MODULE_STRING; \
|
||||
p_module->psz_shortname = MODULE_STRING; \
|
||||
p_module->psz_name = NULL; \
|
||||
p_module->psz_shortname = NULL; \
|
||||
p_module->psz_longname = MODULE_STRING; \
|
||||
p_module->pp_shortcuts[ 0 ] = MODULE_STRING; \
|
||||
p_module->i_cpu = 0; \
|
||||
@ -163,9 +162,6 @@
|
||||
#define set_shortname( desc ) \
|
||||
p_submodule->psz_shortname = desc
|
||||
|
||||
#define set_name( desc ) \
|
||||
p_submodule->psz_name = desc
|
||||
|
||||
#define set_description( desc ) \
|
||||
p_submodule->psz_longname = desc
|
||||
|
||||
|
@ -98,6 +98,7 @@ vlc_module_begin();
|
||||
add_usage_hint( N_("cddax://[device-or-file][@[T]track]") );
|
||||
set_description( _("Compact Disc Digital Audio (CD-DA) input") );
|
||||
set_capability( "access2", 10 /* compare with priority of cdda */ );
|
||||
set_shortname( N_("Audio CD"));
|
||||
set_callbacks( E_(CDDAOpen), E_(CDDAClose) );
|
||||
add_shortcut( "cddax" );
|
||||
add_shortcut( "cd" );
|
||||
|
@ -60,6 +60,7 @@ static void Close( vlc_object_t * );
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Screen Input") );
|
||||
set_shortname( N_("Screen" ));
|
||||
set_category( CAT_INPUT );
|
||||
set_subcategory( SUBCAT_INPUT_ACCESS );
|
||||
|
||||
|
@ -38,6 +38,7 @@ static void Close( vlc_object_t * );
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Dummy stream output") );
|
||||
set_shortname( N_( "Dummy" ));
|
||||
set_capability( "sout access", 0 );
|
||||
set_category( CAT_SOUT );
|
||||
set_subcategory( SUBCAT_SOUT_ACO );
|
||||
|
@ -65,6 +65,7 @@ static void Close( vlc_object_t * );
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("File stream output") );
|
||||
set_shortname( N_("File" ));
|
||||
set_capability( "sout access", 50 );
|
||||
set_category( CAT_SOUT );
|
||||
set_subcategory( SUBCAT_SOUT_ACO );
|
||||
|
@ -74,6 +74,7 @@ static void Close( vlc_object_t * );
|
||||
vlc_module_begin();
|
||||
set_description( _("HTTP stream output") );
|
||||
set_capability( "sout access", 0 );
|
||||
set_shortname( N_("HTTP" ) );
|
||||
add_shortcut( "http" );
|
||||
add_shortcut( "https" );
|
||||
add_shortcut( "mmsh" );
|
||||
|
@ -87,6 +87,7 @@ static void Close( vlc_object_t * );
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("UDP stream output") );
|
||||
set_shortname( N_( "UDP" ) );
|
||||
set_category( CAT_SOUT );
|
||||
set_subcategory( SUBCAT_SOUT_ACO );
|
||||
add_integer( SOUT_CFG_PREFIX "caching", DEFAULT_PTS_DELAY / 1000, NULL, CACHING_TEXT, CACHING_LONGTEXT, VLC_TRUE );
|
||||
|
@ -63,6 +63,7 @@ static void Close( vlc_object_t * );
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Equalizer 10 bands") );
|
||||
set_shortname( N_("Equalizer" ) );
|
||||
set_capability( "audio filter", 0 );
|
||||
set_category( CAT_AUDIO );
|
||||
set_subcategory( SUBCAT_AUDIO_AFILTER );
|
||||
|
@ -80,6 +80,7 @@ typedef struct aout_filter_sys_t
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Volume normalizer") );
|
||||
set_shortname( N_("Volume normalizer") );
|
||||
set_category( CAT_AUDIO );
|
||||
set_subcategory( SUBCAT_AUDIO_AFILTER );
|
||||
add_shortcut( "volnorm" );
|
||||
|
@ -131,6 +131,7 @@ public:
|
||||
wxBoxSizer *sizer;
|
||||
|
||||
int i_object_id;
|
||||
int i_subcat_id;
|
||||
int i_type;
|
||||
char *psz_name;
|
||||
char *psz_help;
|
||||
@ -302,7 +303,7 @@ void PrefsDialog::OnAdvanced( wxCommandEvent& event )
|
||||
PrefsTreeCtrl::PrefsTreeCtrl( wxWindow *_p_parent, intf_thread_t *_p_intf,
|
||||
PrefsDialog *_p_prefs_dialog,
|
||||
wxBoxSizer *_p_sizer )
|
||||
: wxTreeCtrl( _p_parent, PrefsTree_Ctrl, wxDefaultPosition, wxDefaultSize,
|
||||
: wxTreeCtrl( _p_parent, PrefsTree_Ctrl, wxDefaultPosition, wxSize(200,-1),
|
||||
wxTR_NO_LINES | wxTR_FULL_ROW_HIGHLIGHT |
|
||||
wxTR_LINES_AT_ROOT | wxTR_HIDE_ROOT |
|
||||
wxTR_HAS_BUTTONS | wxTR_TWIST_BUTTONS | wxSUNKEN_BORDER )
|
||||
@ -376,7 +377,7 @@ PrefsTreeCtrl::PrefsTreeCtrl( wxWindow *_p_parent, intf_thread_t *_p_intf,
|
||||
ConfigTreeData *cd = (ConfigTreeData *)
|
||||
GetItemData( current_item );
|
||||
cd->i_type = TYPE_CATSUBCAT;
|
||||
cd->i_object_id = p_item->i_value;
|
||||
cd->i_subcat_id = p_item->i_value;
|
||||
if( cd->psz_name ) free( cd->psz_name );
|
||||
cd->psz_name = strdup( config_CategoryNameGet(
|
||||
p_item->i_value ) );
|
||||
@ -443,6 +444,7 @@ PrefsTreeCtrl::PrefsTreeCtrl( wxWindow *_p_parent, intf_thread_t *_p_intf,
|
||||
else
|
||||
p_item = p_module->p_config;
|
||||
|
||||
|
||||
if( !p_item ) continue;
|
||||
do
|
||||
{
|
||||
@ -512,8 +514,8 @@ PrefsTreeCtrl::PrefsTreeCtrl( wxWindow *_p_parent, intf_thread_t *_p_intf,
|
||||
p_module->i_object_id;
|
||||
config_data->psz_help = NULL;
|
||||
|
||||
AppendItem( subcategory_item, wxU( p_module->psz_name ?
|
||||
p_module->psz_name : p_module->psz_object_name)
|
||||
AppendItem( subcategory_item, wxU( p_module->psz_shortname ?
|
||||
p_module->psz_shortname : p_module->psz_object_name )
|
||||
, -1, -1,
|
||||
config_data );
|
||||
}
|
||||
@ -829,7 +831,10 @@ PrefsPanel::PrefsPanel( wxWindow* parent, intf_thread_t *_p_intf,
|
||||
do
|
||||
{
|
||||
if( p_item->i_type == CONFIG_SUBCATEGORY &&
|
||||
p_item->i_value == config_data->i_object_id )
|
||||
( config_data->i_type == TYPE_SUBCATEGORY &&
|
||||
p_item->i_value == config_data->i_object_id ) ||
|
||||
( config_data->i_type == TYPE_CATSUBCAT &&
|
||||
p_item->i_value == config_data->i_subcat_id ) )
|
||||
{
|
||||
break;
|
||||
}
|
||||
@ -870,11 +875,12 @@ PrefsPanel::PrefsPanel( wxWindow* parent, intf_thread_t *_p_intf,
|
||||
if( p_item ) do
|
||||
{
|
||||
/* If a category has been specified, check we finished the job */
|
||||
if( (config_data->i_type == TYPE_SUBCATEGORY ||
|
||||
config_data->i_type == TYPE_CATSUBCAT ) &&
|
||||
if( ( ( config_data->i_type == TYPE_SUBCATEGORY &&
|
||||
p_item->i_value != config_data->i_object_id ) ||
|
||||
( config_data->i_type == TYPE_CATSUBCAT &&
|
||||
p_item->i_value != config_data->i_subcat_id ) ) &&
|
||||
(p_item->i_type == CONFIG_CATEGORY ||
|
||||
p_item->i_type == CONFIG_SUBCATEGORY ) &&
|
||||
p_item->i_value != config_data->i_object_id )
|
||||
p_item->i_type == CONFIG_SUBCATEGORY ) )
|
||||
break;
|
||||
|
||||
ConfigControl *control =
|
||||
|
@ -45,9 +45,11 @@ static void Close( vlc_object_t * );
|
||||
|
||||
#define HOST_TEXT N_( "Host address" )
|
||||
#define HOST_LONGTEXT N_( \
|
||||
"You can set the address, port and path the rtsp interface will bind to." )
|
||||
|
||||
"You can set the address, port and path the rtsp interface will bind to." \
|
||||
".\n Syntax is address:port/path. Default is to bind to localhost address"\
|
||||
"on port 554, with no path. Use 0.0.0.0 to bind to all addresses." )
|
||||
vlc_module_begin();
|
||||
set_shortname( _("RTSP VoD" ) );
|
||||
set_description( _("RTSP VoD server") );
|
||||
set_category( CAT_SOUT );
|
||||
set_subcategory( SUBCAT_SOUT_VOD );
|
||||
|
@ -71,6 +71,7 @@ static int SendEvents( vlc_object_t *, char const *,
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Image properties filter") );
|
||||
set_shortname( N_("Image adjust" ));
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
set_capability( "video filter", 0 );
|
||||
|
@ -62,6 +62,7 @@ static int SendEvents( vlc_object_t *, char const *,
|
||||
vlc_module_begin();
|
||||
set_description( _("Clone video filter") );
|
||||
set_capability( "video filter", 0 );
|
||||
set_shortname( N_("Clone" ));
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
|
||||
|
@ -59,6 +59,7 @@ static int SendEvents( vlc_object_t *, char const *,
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Crop video filter") );
|
||||
set_shortname( N_("Crop" ));
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
set_capability( "video filter", 0 );
|
||||
|
@ -64,6 +64,7 @@ static char *mode_list_text[] = { N_("Wave"), N_("Ripple") };
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Distort video filter") );
|
||||
set_shortname( N_( "Distortion" ));
|
||||
set_capability( "video filter", 0 );
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
|
@ -50,6 +50,7 @@ static int SendEvents( vlc_object_t *, char const *,
|
||||
*****************************************************************************/
|
||||
vlc_module_begin();
|
||||
set_description( _("Invert video filter") );
|
||||
set_shortname( N_("Color inversion" ));
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
set_capability( "video filter", 0 );
|
||||
|
@ -84,6 +84,7 @@ static char *ppsz_pos_descriptions[] =
|
||||
vlc_module_begin();
|
||||
set_description( _("Logo video filter") );
|
||||
set_capability( "video filter", 0 );
|
||||
set_shortname( N_("Logo overlay") );
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
add_shortcut( "logo" );
|
||||
|
1
modules/video_filter/marq.c
Executable file → Normal file
1
modules/video_filter/marq.c
Executable file → Normal file
@ -77,6 +77,7 @@ struct filter_sys_t
|
||||
*****************************************************************************/
|
||||
vlc_module_begin();
|
||||
set_capability( "sub filter", 0 );
|
||||
set_shortname( N_("Marquee" ));
|
||||
set_callbacks( CreateFilter, DestroyFilter );
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_SUBPIC );
|
||||
|
@ -64,6 +64,7 @@ struct filter_sys_t
|
||||
*****************************************************************************/
|
||||
vlc_module_begin();
|
||||
set_capability( "sub filter", 0 );
|
||||
set_shortname( N_("Time overlay"));
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_SUBPIC );
|
||||
set_callbacks( CreateFilter, DestroyFilter );
|
||||
|
@ -64,6 +64,7 @@ static char *type_list_text[] = { N_("Rotate by 90 degrees"),
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("Video transformation filter") );
|
||||
set_shortname( N_("Transformation"));
|
||||
set_capability( "video filter", 0 );
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
|
@ -64,6 +64,7 @@ static int SendEvents( vlc_object_t *, char const *,
|
||||
|
||||
vlc_module_begin();
|
||||
set_description( _("wall video filter") );
|
||||
set_shortname( N_("Image wall" ));
|
||||
set_capability( "video filter", 0 );
|
||||
set_category( CAT_VIDEO );
|
||||
set_subcategory( SUBCAT_VIDEO_VFILTER );
|
||||
|
@ -1,7 +1,7 @@
|
||||
/*****************************************************************************
|
||||
* fft.c: Iterative implementation of a FFT
|
||||
*****************************************************************************
|
||||
* $Id: fft.c,v 1.3 2003/12/22 14:32:56 sam Exp $
|
||||
* $Id$
|
||||
*
|
||||
* Mainly taken from XMMS's code
|
||||
*
|
||||
|
@ -1,7 +1,7 @@
|
||||
/*****************************************************************************
|
||||
* fft.h: Headers for iterative implementation of a FFT
|
||||
*****************************************************************************
|
||||
* $Id: fft.h,v 1.2 2003/10/24 17:43:51 sam Exp $
|
||||
* $Id$
|
||||
*
|
||||
* Mainly taken from XMMS's code
|
||||
*
|
||||
|
@ -2,7 +2,7 @@
|
||||
* visual.h : Header for the visualisation system
|
||||
*****************************************************************************
|
||||
* Copyright (C) 2002 VideoLAN
|
||||
* $Id: visual.h,v 1.5 2003/09/20 00:37:53 fenrir Exp $
|
||||
* $Id$
|
||||
*
|
||||
* Authors: Clément Stenac <zorglub@via.ecp.fr>
|
||||
*
|
||||
|
@ -1128,7 +1128,8 @@ static void DupModule( module_t *p_module )
|
||||
* module is unloaded. */
|
||||
p_module->psz_object_name = strdup( p_module->psz_object_name );
|
||||
p_module->psz_capability = strdup( p_module->psz_capability );
|
||||
p_module->psz_shortname = strdup( p_module->psz_shortname );
|
||||
p_module->psz_shortname = p_module->psz_shortname ?
|
||||
strdup( p_module->psz_shortname ) : NULL;
|
||||
p_module->psz_longname = strdup( p_module->psz_longname );
|
||||
|
||||
if( p_module->psz_program != NULL )
|
||||
|
Loading…
Reference in New Issue
Block a user