Commit f716766a authored by Olivier Teulière's avatar Olivier Teulière

* src/misc/objects.c: vlc_list_find now returns a (vlc_list_t *)

   instead of a (vlc_list_t); this modification was needed because BCB
   doesn't like at all when a function (compiled with mingw32) returns
   a struct...
 * ALL: modified the files to take this change into account
 * modules/gui/win32/menu.cpp: enabled the "Add interface" command
parent 5b84049b
......@@ -2,7 +2,7 @@
* vlc_objects.h: vlc_object_t definition.
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: vlc_objects.h,v 1.14 2002/12/13 01:56:29 gbazin Exp $
* $Id: vlc_objects.h,v 1.15 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
......@@ -61,7 +61,7 @@ VLC_EXPORT( void *, __vlc_object_get, ( vlc_object_t *, int ) );
VLC_EXPORT( void *, __vlc_object_find, ( vlc_object_t *, int, int ) );
VLC_EXPORT( void, __vlc_object_yield, ( vlc_object_t * ) );
VLC_EXPORT( void, __vlc_object_release, ( vlc_object_t * ) );
VLC_EXPORT( vlc_list_t, __vlc_list_find, ( vlc_object_t *, int, int ) );
VLC_EXPORT( vlc_list_t *, __vlc_list_find, ( vlc_object_t *, int, int ) );
VLC_EXPORT( void, vlc_list_release, ( vlc_list_t * ) );
#define vlc_object_create(a,b) \
......
......@@ -2,7 +2,7 @@
* familiar.c : familiar plugin for vlc
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: familiar.c,v 1.27 2003/01/17 18:19:11 jpsaman Exp $
* $Id: familiar.c,v 1.28 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Jean-Paul Saman <jpsaman@wxs.nl>
*
......@@ -261,11 +261,12 @@ void GtkAutoPlayFile( vlc_object_t *p_this )
GtkWidget *cbautoplay;
intf_thread_t *p_intf;
int i_index;
vlc_list_t list = vlc_list_find( p_this, VLC_OBJECT_INTF, FIND_ANYWHERE );
vlc_list_t *p_list = vlc_list_find( p_this, VLC_OBJECT_INTF,
FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_intf = (intf_thread_t *)list.p_values[i_index].p_object ;
p_intf = (intf_thread_t *)p_list->p_values[i_index].p_object ;
if( strcmp( MODULE_STRING, p_intf->p_module->psz_object_name ) )
{
......@@ -286,7 +287,7 @@ void GtkAutoPlayFile( vlc_object_t *p_this )
gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( cbautoplay ),
p_intf->p_sys->b_autoplayfile );
}
vlc_list_release( &list );
vlc_list_release( p_list );
}
/* following functions are local */
......
......@@ -2,7 +2,7 @@
* display.c: Gtk+ tools for main interface
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: display.c,v 1.7 2003/01/20 20:07:06 fenrir Exp $
* $Id: display.c,v 1.8 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Samuel Hocevar <sam@zoy.org>
* Stphane Borel <stef@via.ecp.fr>
......@@ -242,14 +242,14 @@ void E_(GtkHideTooltips)( vlc_object_t *p_this )
{
intf_thread_t *p_intf;
int i_index;
vlc_list_t list = vlc_list_find( p_this, VLC_OBJECT_INTF,
FIND_ANYWHERE );
vlc_list_t *p_list = vlc_list_find( p_this, VLC_OBJECT_INTF,
FIND_ANYWHERE );
vlc_bool_t b_enable = config_GetInt( p_this, "gnome-tooltips" );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_intf = (intf_thread_t *)list.p_values[i_index].p_object ;
p_intf = (intf_thread_t *)p_list->p_values[i_index].p_object ;
if( strcmp( MODULE_STRING, p_intf->p_module->psz_object_name ) )
{
......@@ -266,7 +266,7 @@ void E_(GtkHideTooltips)( vlc_object_t *p_this )
}
}
vlc_list_release( &list );
vlc_list_release( p_list );
}
#ifdef MODULE_NAME_IS_gnome
......@@ -282,16 +282,16 @@ void GtkHideToolbarText( vlc_object_t *p_this )
GtkToolbar * p_toolbar;
intf_thread_t *p_intf;
int i_index;
vlc_list_t list = vlc_list_find( p_this, VLC_OBJECT_INTF,
FIND_ANYWHERE );
vlc_list_t *p_list = vlc_list_find( p_this, VLC_OBJECT_INTF,
FIND_ANYWHERE );
style = config_GetInt( p_this, "gnome-toolbartext" )
? GTK_TOOLBAR_BOTH
: GTK_TOOLBAR_ICONS;
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_intf = (intf_thread_t *)list.p_values[i_index].p_object ;
p_intf = (intf_thread_t *)p_list->p_values[i_index].p_object ;
if( strcmp( MODULE_STRING, p_intf->p_module->psz_object_name ) )
{
......@@ -303,6 +303,6 @@ void GtkHideToolbarText( vlc_object_t *p_this )
gtk_toolbar_set_style( p_toolbar, style );
}
vlc_list_release( &list );
vlc_list_release( p_list );
}
#endif
......@@ -2,7 +2,7 @@
* gtk_preferences.c: functions to handle the preferences dialog box.
*****************************************************************************
* Copyright (C) 2000, 2001 VideoLAN
* $Id: preferences.c,v 1.7 2003/01/06 00:37:30 garf Exp $
* $Id: preferences.c,v 1.8 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Gildas Bazin <gbazin@netcourrier.com>
* Loc Minier <lool@via.ecp.fr>
......@@ -121,7 +121,7 @@ static void GtkCreateConfigDialog( char *psz_module_name,
intf_thread_t *p_intf )
{
module_t *p_parser = NULL;
vlc_list_t list;
vlc_list_t *p_list;
module_config_t *p_item;
int i_index;
......@@ -179,11 +179,11 @@ static void GtkCreateConfigDialog( char *psz_module_name,
/* Look for the selected module */
list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( psz_module_name
&& !strcmp( psz_module_name, p_parser->psz_object_name ) )
......@@ -192,9 +192,9 @@ static void GtkCreateConfigDialog( char *psz_module_name,
}
}
if( !p_parser || i_index == list.i_count )
if( !p_parser || i_index == p_list->i_count )
{
vlc_list_release( &list );
vlc_list_release( p_list );
return;
}
......@@ -334,9 +334,9 @@ static void GtkCreateConfigDialog( char *psz_module_name,
{
gchar * entry[2];
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !strcmp( p_parser->psz_capability,
p_item->psz_type ) )
......@@ -560,7 +560,7 @@ static void GtkCreateConfigDialog( char *psz_module_name,
}
while( p_item->i_type != CONFIG_HINT_END && p_item++ );
vlc_list_release( &list );
vlc_list_release( p_list );
#ifndef MODULE_NAME_IS_gnome
/* Now let's add the action buttons at the bottom of the page */
......@@ -704,7 +704,7 @@ static void GtkModuleHighlighted( GtkCList *module_clist, int row, int column,
intf_thread_t *p_intf;
GtkWidget *config_button;
module_t *p_parser;
vlc_list_t list;
vlc_list_t *p_list;
char *psz_name;
int i_index;
......@@ -717,11 +717,11 @@ static void GtkModuleHighlighted( GtkCList *module_clist, int row, int column,
}
/* look for module 'psz_name' */
list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !strcmp( p_parser->psz_object_name, psz_name ) )
{
......@@ -738,7 +738,7 @@ static void GtkModuleHighlighted( GtkCList *module_clist, int row, int column,
}
}
vlc_list_release( &list );
vlc_list_release( p_list );
}
/****************************************************************************
......
......@@ -2,7 +2,7 @@
* preferences.cpp: preferences window for the kde gui
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: preferences.cpp,v 1.10 2002/12/17 09:54:32 sam Exp $
* $Id: preferences.cpp,v 1.11 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Sigmund Augdal <sigmunau@idi.ntnu.no> Mon Aug 12 2002
*
......@@ -53,7 +53,7 @@ KPreferences::KPreferences(intf_thread_t *p_intf, const char *psz_module_name,
"vlc preferences", true, false, "Save")
{
module_t *p_parser = NULL;
vlc_list_t list;
vlc_list_t *p_list;
module_config_t *p_item;
int i_index;
QVBox *category_table = NULL;
......@@ -62,12 +62,12 @@ KPreferences::KPreferences(intf_thread_t *p_intf, const char *psz_module_name,
this->p_intf = p_intf;
/* List all modules */
list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
/* Look for the selected module */
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( psz_module_name
&& !strcmp( psz_module_name, p_parser->psz_object_name ) )
......@@ -76,9 +76,9 @@ KPreferences::KPreferences(intf_thread_t *p_intf, const char *psz_module_name,
}
}
if( !p_parser || i_index == list.i_count )
if( !p_parser || i_index == p_list->i_count )
{
vlc_list_release( &list );
vlc_list_release( p_list );
return;
}
......@@ -130,9 +130,9 @@ KPreferences::KPreferences(intf_thread_t *p_intf, const char *psz_module_name,
/* build a list of available plugins */
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !strcmp( p_parser->psz_capability,
p_item->psz_type ) )
......@@ -251,7 +251,7 @@ KPreferences::KPreferences(intf_thread_t *p_intf, const char *psz_module_name,
}
while( p_item->i_type != CONFIG_HINT_END );
vlc_list_release( &list );
vlc_list_release( p_list );
exec();
}
......@@ -269,24 +269,24 @@ KPreferences::~KPreferences()
bool KPreferences::isConfigureable(QString module)
{
module_t *p_parser;
vlc_list_t list;
vlc_list_t *p_list;
int i_index;
list = vlc_list_find( this->p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( this->p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !module.compare( p_parser->psz_object_name ) )
{
bool ret = p_parser->i_config_items != 0;
vlc_list_release( &list );
vlc_list_release( p_list );
return ret;
}
}
vlc_list_release( &list );
vlc_list_release( p_list );
return false;
}
......
......@@ -2,15 +2,15 @@
* prefs.m: MacOS X plugin for vlc
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: prefs.m,v 1.8 2003/01/27 00:08:31 jlj Exp $
* $Id: prefs.m,v 1.9 2003/01/27 17:41:01 ipkiss Exp $
*
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
......@@ -37,7 +37,7 @@
#import "prefs.h"
/*****************************************************************************
* VLCPrefs implementation
* VLCPrefs implementation
*****************************************************************************/
@implementation VLCPrefs
......@@ -49,7 +49,7 @@
{
p_intf = [NSApp getIntf];
o_pref_panels = [[NSMutableDictionary alloc] init];
o_pref_panels = [[NSMutableDictionary alloc] init];
o_toolbars = [[NSMutableDictionary alloc] init];
o_scroll_views = [[NSMutableDictionary alloc] init];
o_panel_views = [[NSMutableDictionary alloc] init];
......@@ -101,28 +101,28 @@
- (BOOL)hasPrefs:(NSString *)o_module_name
{
module_t *p_parser;
vlc_list_t list;
vlc_list_t *p_list;
char *psz_module_name;
int i_index;
psz_module_name = (char *)[o_module_name lossyCString];
/* look for module */
list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !strcmp( p_parser->psz_object_name, psz_module_name ) )
{
BOOL b_has_prefs = p_parser->i_config_items != 0;
vlc_list_release( &list );
vlc_list_release( p_list );
return( b_has_prefs );
}
}
vlc_list_release( &list );
vlc_list_release( p_list );
return( NO );
}
......@@ -133,7 +133,7 @@
int i_module_tag;
module_t *p_parser = NULL;
vlc_list_t list;
vlc_list_t *p_list;
module_config_t *p_item;
char *psz_module_name;
int i_index;
......@@ -143,7 +143,7 @@
NSView *o_panel_view; /* panel view */
NSToolbar *o_toolbar; /* panel toolbar */
NSMutableDictionary *o_tb_items; /* panel toolbar items */
NSScrollView *o_scroll_view; /* panel scroll view */
NSScrollView *o_scroll_view; /* panel scroll view */
NSRect s_scroll_rc; /* panel scroll view rect */
NSMutableDictionary *o_views; /* panel scroll view docviews */
......@@ -160,16 +160,16 @@
[o_panel center];
[o_panel makeKeyAndOrderFront: nil];
return;
}
}
psz_module_name = (char *)[o_module_name lossyCString];
/* Look for the selected module */
list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
p_list = vlc_list_find( p_intf, VLC_OBJECT_MODULE, FIND_ANYWHERE );
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( psz_module_name
&& !strcmp( psz_module_name, p_parser->psz_object_name ) )
......@@ -178,9 +178,9 @@
}
}
if( !p_parser || i_index == list.i_count )
if( !p_parser || i_index == p_list->i_count )
{
vlc_list_release( &list );
vlc_list_release( p_list );
return;
}
......@@ -192,15 +192,15 @@
backing: NSBackingStoreBuffered
defer: YES];
o_toolbar = [[NSToolbar alloc] initWithIdentifier: o_module_name];
[o_panel setTitle: [NSString stringWithFormat: @"%@ (%@)",
[o_panel setTitle: [NSString stringWithFormat: @"%@ (%@)",
_NS("Preferences"), o_module_name]];
o_panel_view = [o_panel contentView];
s_scroll_rc = s_panel_rc;
s_scroll_rc = s_panel_rc;
s_scroll_rc.size.height -= 55; s_scroll_rc.origin.y += 55;
o_scroll_view = [[NSScrollView alloc] initWithFrame: s_scroll_rc];
[o_scroll_views setObject: o_scroll_view forKey: o_module_name];
[o_scroll_view setBorderType: NSGrooveBorder];
[o_scroll_view setBorderType: NSGrooveBorder];
[o_scroll_view setHasVerticalScroller: YES];
[o_scroll_view setDrawsBackground: NO];
[o_scroll_view setRulersVisible: YES];
......@@ -220,7 +220,7 @@
i_module_tag = 3;
#define X_ORIGIN 20
#define Y_ORIGIN (X_ORIGIN - 10)
#define Y_ORIGIN (X_ORIGIN - 10)
#define CHECK_VIEW_HEIGHT \
{ \
......@@ -287,14 +287,14 @@
NSToolbarItem *o_tbi;
o_label = [NSApp localizedString: p_item->psz_text];
o_tbi = [[NSToolbarItem alloc] initWithItemIdentifier: o_label];
o_tbi = [[NSToolbarItem alloc] initWithItemIdentifier: o_label];
[o_tbi setImage: [NSImage imageNamed: @"NSApplicationIcon"]];
[o_tbi setLabel: o_label];
[o_tbi setTarget: self];
[o_tbi setAction: @selector(selectPrefView:)];
o_key = [NSString stringWithFormat: @"%02d %@",
i_pos, o_label];
i_pos, o_label];
[o_tb_items setObject: o_tbi forKey: o_key];
s_vrc = s_scroll_rc; s_vrc.size.height -= 4;
......@@ -308,7 +308,7 @@
if( i_pos == 0 )
{
[o_scroll_view setDocumentView: o_view];
[o_scroll_view setDocumentView: o_view];
}
i_pos++;
......@@ -353,23 +353,23 @@
[o_box setContentView: [o_cview autorelease]];
s_crc = [o_cview bounds];
s_brc = NSMakeRect( 5, 10, 200, 30 );
s_brc = NSMakeRect( 5, 10, 200, 30 );
o_modules = [[NSPopUpButton alloc] initWithFrame: s_brc];
[o_modules setTag: i_module_tag++];
[o_modules setTarget: self];
[o_modules setAction: @selector(moduleSelected:)];
[o_modules setToolTip: [NSApp localizedString: p_item->psz_longtext]];
[o_cview addSubview: [o_modules autorelease]];
[o_cview addSubview: [o_modules autorelease]];
MODULE_BUTTON( o_btn_configure, _NS("Configure"),
MODULE_BUTTON( o_btn_configure, _NS("Configure"),
configureModule: );
s_brc = NSMakeRect( 8, s_brc.origin.y + s_brc.size.height + 10,
194, 25 );
s_brc = NSMakeRect( 8, s_brc.origin.y + s_brc.size.height + 10,
194, 25 );
o_text_field = [[VLCTextField alloc] initWithFrame: s_brc];
[o_text_field setTag: i_module_tag++];
[o_text_field setAlignment: NSLeftTextAlignment];
CONTROL_CONFIG( o_text_field, o_module_name,
CONTROL_CONFIG( o_text_field, o_module_name,
CONFIG_ITEM_MODULE, p_item->psz_name );
[[NSNotificationCenter defaultCenter] addObserver: self
selector: @selector(configChanged:)
......@@ -378,21 +378,21 @@
[o_cview addSubview: [o_text_field autorelease]];
s_brc.origin.x += 3;
MODULE_BUTTON( o_btn_select, _NS("Select"),
MODULE_BUTTON( o_btn_select, _NS("Select"),
selectModule: );
[o_modules addItemWithTitle: _NS("None")];
/* build a list of available modules */
{
for( i_index = 0; i_index < list.i_count; i_index++ )
for( i_index = 0; i_index < p_list->i_count; i_index++ )
{
p_parser = (module_t *)list.p_values[i_index].p_object ;
p_parser = (module_t *)p_list->p_values[i_index].p_object ;
if( !strcmp( p_parser->psz_capability,
p_item->psz_type ) )
{
NSString *o_object_name = [NSString
NSString *o_object_name = [NSString
stringWithCString: p_parser->psz_object_name];
[o_modules addItemWithTitle: o_object_name];
}
......@@ -404,9 +404,9 @@
NSString *o_value =
[NSString stringWithCString: p_item->psz_value];
[o_text_field setStringValue: o_value];
[o_modules selectItemWithTitle: o_value];
[o_btn_configure setEnabled: [self hasPrefs: o_value]];
[o_text_field setStringValue: o_value];
[o_modules selectItemWithTitle: o_value];
[o_btn_configure setEnabled: [self hasPrefs: o_value]];
}
else
{
......@@ -443,7 +443,7 @@
CHECK_VIEW_HEIGHT;
o_combo_box = [[VLCComboBox alloc] initWithFrame: s_rc];
CONTROL_CONFIG( o_combo_box, o_module_name,
CONTROL_CONFIG( o_combo_box, o_module_name,
CONFIG_ITEM_STRING, p_item->psz_name );
[o_combo_box setToolTip:
[NSApp localizedString: p_item->psz_longtext]];
......@@ -454,16 +454,16 @@
object: o_combo_box];
[[NSNotificationCenter defaultCenter] addObserver: self
selector: @selector(configChanged:)
name: NSComboBoxSelectionDidChangeNotification
name: NSComboBoxSelectionDidChangeNotification
object: o_combo_box];
for( i=0; p_item->ppsz_list[i]; i++ )
{
[o_combo_box addItemWithObjectValue:
[NSString stringWithCString: p_item->ppsz_list[i]]];
[NSString stringWithCString: p_item->ppsz_list[i]]];
}
CONTROL_LABEL( p_item->psz_text );
CONTROL_LABEL( p_item->psz_text );
s_rc.origin.y += s_rc.size.height;
s_rc.origin.x = X_ORIGIN;
......@@ -474,7 +474,7 @@
case CONFIG_ITEM_INTEGER:
{
INPUT_FIELD_INTEGER( p_item->psz_name, p_item->psz_text, 70,
INPUT_FIELD_INTEGER( p_item->psz_name, p_item->psz_text, 70,
p_item->i_value, p_item->psz_longtext );
}
break;
......@@ -499,14 +499,14 @@
o_btn_bool = [[VLCButton alloc] initWithFrame: s_rc];
[o_btn_bool setButtonType: NSSwitchButton];
[o_btn_bool setIntValue: p_item->i_value];
[o_btn_bool setTitle:
[o_btn_bool setTitle:
[NSApp localizedString: p_item->psz_text]];
[o_btn_bool setToolTip:
[NSApp localizedString: p_item->psz_longtext]];
[o_btn_bool setTarget: self];
[o_btn_bool setAction: @selector(configChanged:)];
CONTROL_CONFIG( o_btn_bool, o_module_name,
CONFIG_ITEM_BOOL, p_item->psz_name );
CONTROL_CONFIG( o_btn_bool, o_module_name,
CONFIG_ITEM_BOOL, p_item->psz_name );
[o_view addSubview: [o_btn_bool autorelease]];
s_rc.origin.y += s_rc.size.height;
......@@ -526,7 +526,7 @@
}
while( p_item->i_type != CONFIG_HINT_END && p_item++ );
vlc_list_release( &list );
vlc_list_release( p_list );
[o_toolbars setObject: o_tb_items forKey: o_module_name];
[o_toolbar setDelegate: self];
......@@ -547,7 +547,7 @@
s_rc.origin.y = s_panel_rc.origin.y + 14;
s_rc.size.height = 25; s_rc.size.width = 100;
s_rc.origin.x = s_panel_rc.size.width - s_rc.size.width - 14;
DEF_PANEL_BUTTON( 0, _NS("OK"), clickedCancelOK: );
DEF_PANEL_BUTTON( 0, _NS("OK"), clickedCancelOK: );
[o_panel setDefaultButtonCell: [o_button cell]];
s_rc.origin.x -= s_rc.size.width;
......@@ -626,7 +626,7 @@
o_view = [o_views objectForKey: [sender label]];
o_scroll_view = [o_scroll_views objectForKey: o_module_name];
[o_scroll_view setDocumentView: o_view];
[o_scroll_view setDocumentView: o_view];
}
- (void)moduleSelected:(id)sender
......@@ -651,7 +651,7 @@
NSString *o_module_name;
NSPopUpButton *o_modules;
o_modules = [[sender superview] viewWithTag: [sender tag] - 1];
o_modules = [[sender superview] viewWithTag: [sender tag] - 1];
o_module_name = [o_modules titleOfSelectedItem];
[self createPrefPanel: o_module_name];
......@@ -681,14 +681,14 @@
id o_vlc_config = [o_unknown isKindOfClass: [NSNotification class]] ?
[o_unknown object] : o_unknown;
NSString *o_module_name = [o_vlc_config moduleName];
NSPanel *o_pref_panel = [o_pref_panels objectForKey: o_module_name];
NSString *o_module_name = [o_vlc_config moduleName];
NSPanel *o_pref_panel = [o_pref_panels objectForKey: o_module_name];
NSMutableArray *o_prefs = [o_save_prefs objectForKey: o_module_name];
if( [o_prefs indexOfObjectIdenticalTo: o_vlc_config] == NSNotFound )
{
NSView *o_pref_view = [o_pref_panel contentView];
NSButton *o_btn_apply = [o_pref_view viewWithTag: 2];
NSButton *o_btn_apply = [o_pref_view viewWithTag: 2];
[o_prefs addObject: o_vlc_config];
[o_btn_apply setEnabled: YES];
......@@ -701,8 +701,8 @@
NSEnumerator *o_enum;
NSView *o_config_view = [sender superview];
NSWindow *o_config_panel = [o_config_view window];
NSButton *o_btn_apply = [o_config_view viewWithTag: 2];
NSWindow *o_config_panel = [o_config_view window];
NSButton *o_btn_apply = [o_config_view viewWithTag: 2];
NSString *o_module_name = [[o_config_panel toolbar] identifier];
NSMutableArray *o_prefs = [o_save_prefs objectForKey: o_module_name];
......@@ -726,7 +726,7 @@
o_value = [o_vlc_control stringValue];
psz_value = (char *)[o_value lossyCString];
config_PutPsz( p_intf, psz_name,
config_PutPsz( p_intf, psz_name,
*psz_value ? psz_value : NULL );
}
break;
......@@ -770,7 +770,7 @@
[o_pref_panel close];
if( [self respondsToSelector: @selector(performSelectorOnMainThread:
withObject:waitUntilDone:)] )
withObject:waitUntilDone:)] )
{
[self performSelectorOnMainThread: @selector(destroyPrefPanel:)
withObject: o_module_name
......@@ -788,8 +788,8 @@
@implementation VLCPrefs (NSToolbarDelegate)
- (NSToolbarItem *)toolbar:(NSToolbar *)o_toolbar
itemForItemIdentifier:(NSString *)o_item_id
- (NSToolbarItem *)toolbar:(NSToolbar *)o_toolbar