From: Jean-Baptiste Kempf Date: Mon, 25 May 2009 22:51:06 +0000 (+0200) Subject: Merge branch '1.0' X-Git-Tag: 1.1.0-ff~5764 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=66bd92014e5d721d8fe74bfd69f601bfd228012a;hp=1319c5c570074abacf35a18d82326ff447c60d03;p=vlc Merge branch '1.0' Conflicts: extras/contrib/Makefile extras/package/macosx/Resources/English.lproj/MainMenu.nib/classes.nib extras/package/macosx/Resources/English.lproj/MainMenu.nib/info.nib extras/package/macosx/Resources/English.lproj/MainMenu.nib/keyedobjects.nib extras/package/macosx/vlc.xcodeproj/project.pbxproj modules/gui/qt4/dialogs/external.cpp projects/mozilla/vlcshell.cpp src/control/event.c src/control/media_list_player.c src/control/media_player.c --- diff --git a/extras/package/macosx/Resources/English.lproj/VLM.nib/classes.nib b/extras/package/macosx/Resources/English.lproj/VLM.nib/classes.nib deleted file mode 100644 index 78fdd7b798..0000000000 --- a/extras/package/macosx/Resources/English.lproj/VLM.nib/classes.nib +++ /dev/null @@ -1,72 +0,0 @@ -{ - IBClasses = ( - { - CLASS = FirstResponder; - LANGUAGE = ObjC; - SUPERCLASS = NSObject; - }, - { - CLASS = NSDatePicker; - LANGUAGE = ObjC; - SUPERCLASS = NSControl; - }, - { - ACTIONS = { - bcastButtonAction = id; - listDoubleClickAction = id; - schedButtonAction = id; - vodButtonAction = id; - }; - CLASS = VLCVLMController; - LANGUAGE = ObjC; - OUTLETS = { - "o_bcast_add_btn" = NSButton; - "o_bcast_box" = NSBox; - "o_bcast_cancel_btn" = NSButton; - "o_bcast_enable_ckb" = NSButton; - "o_bcast_input_btn" = NSButton; - "o_bcast_input_fld" = NSTextField; - "o_bcast_loop_ckb" = NSButton; - "o_bcast_name_fld" = NSTextField; - "o_bcast_output_btn" = NSButton; - "o_bcast_output_fld" = NSTextField; - "o_bcast_panel" = NSPanel; - "o_sched_add_btn" = id; - "o_sched_box" = id; - "o_sched_cancel_btn" = id; - "o_sched_date_datePicker" = NSDatePicker; - "o_sched_date_lbl" = NSTextField; - "o_sched_input_btn" = NSButton; - "o_sched_input_fld" = NSTextField; - "o_sched_input_lbl" = NSTextField; - "o_sched_name_fld" = NSTextField; - "o_sched_name_lbl" = NSTextField; - "o_sched_output_btn" = NSButton; - "o_sched_output_fld" = NSTextField; - "o_sched_output_lbl" = NSTextField; - "o_sched_panel" = NSPanel; - "o_sched_repeatDelay_datePicker" = NSDatePicker; - "o_sched_repeat_fld" = NSTextField; - "o_sched_repeat_lbl" = NSTextField; - "o_sched_time_box" = id; - "o_vlm_list" = NSTableView; - "o_vlm_win" = NSWindow; - "o_vod_add_btn" = NSButton; - "o_vod_box" = id; - "o_vod_cancel_btn" = NSButton; - "o_vod_input_btn" = NSButton; - "o_vod_input_fld" = NSTextField; - "o_vod_input_lbl" = NSTextField; - "o_vod_loop_ckb" = NSButton; - "o_vod_name_fld" = NSTextField; - "o_vod_name_lbl" = NSTextField; - "o_vod_output_btn" = NSButton; - "o_vod_output_fld" = NSTextField; - "o_vod_output_lbl" = NSTextField; - "o_vod_panel" = NSPanel; - }; - SUPERCLASS = NSObject; - } - ); - IBVersion = 1; -} \ No newline at end of file diff --git a/extras/package/macosx/Resources/English.lproj/VLM.nib/info.nib b/extras/package/macosx/Resources/English.lproj/VLM.nib/info.nib deleted file mode 100644 index ea3c540486..0000000000 --- a/extras/package/macosx/Resources/English.lproj/VLM.nib/info.nib +++ /dev/null @@ -1,19 +0,0 @@ - - - - - IBDocumentLocation - 609 119 356 240 0 0 1280 778 - IBFramework Version - 489.0 - IBOpenObjects - - 5 - 106 - 65 - 30 - - IBSystem Version - 9E17 - - diff --git a/extras/package/macosx/Resources/English.lproj/VLM.nib/keyedobjects.nib b/extras/package/macosx/Resources/English.lproj/VLM.nib/keyedobjects.nib deleted file mode 100644 index b078329552..0000000000 Binary files a/extras/package/macosx/Resources/English.lproj/VLM.nib/keyedobjects.nib and /dev/null differ diff --git a/extras/package/macosx/vlc.xcodeproj/project.pbxproj b/extras/package/macosx/vlc.xcodeproj/project.pbxproj index 21e6a975d6..4d54cfae1a 100644 --- a/extras/package/macosx/vlc.xcodeproj/project.pbxproj +++ b/extras/package/macosx/vlc.xcodeproj/project.pbxproj @@ -359,8 +359,6 @@ CC965D5F0DA5880F0088F222 /* display_right.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = display_right.png; path = Resources/display_right.png; sourceTree = ""; }; CCB24D5D0D54BBAE004D780C /* simple_prefs.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; lineEnding = 0; name = simple_prefs.m; path = ../../../modules/gui/macosx/simple_prefs.m; sourceTree = SOURCE_ROOT; }; CCB24D5E0D54BBAE004D780C /* simple_prefs.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = simple_prefs.h; path = ../../../modules/gui/macosx/simple_prefs.h; sourceTree = SOURCE_ROOT; }; - CCB60A3E0E6E5DD900407004 /* vlm.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = vlm.m; path = ../../../modules/gui/macosx/vlm.m; sourceTree = SOURCE_ROOT; }; - CCB60A3F0E6E5DD900407004 /* vlm.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = vlm.h; path = ../../../modules/gui/macosx/vlm.h; sourceTree = SOURCE_ROOT; }; CCB60A410E6E5E3F00407004 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = Resources/English.lproj/VLM.nib; sourceTree = ""; }; CCBE999E0F922C51000705F8 /* CoreServices.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreServices.framework; path = /System/Library/Frameworks/CoreServices.framework; sourceTree = ""; }; CCC593780AB4A9FB0004FF52 /* embeddedwindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = embeddedwindow.h; path = ../../../modules/gui/macosx/embeddedwindow.h; sourceTree = SOURCE_ROOT; }; diff --git a/modules/gui/macosx/Modules.am b/modules/gui/macosx/Modules.am index 590f8e6d80..922f4568be 100644 --- a/modules/gui/macosx/Modules.am +++ b/modules/gui/macosx/Modules.am @@ -56,7 +56,5 @@ SOURCES_macosx = \ fspanel.h \ eyetv.h \ eyetv.m \ - vlm.h \ - vlm.m \ $(NULL) diff --git a/modules/gui/macosx/intf.h b/modules/gui/macosx/intf.h index 5c5600084b..03eccd7d92 100644 --- a/modules/gui/macosx/intf.h +++ b/modules/gui/macosx/intf.h @@ -102,7 +102,6 @@ struct intf_sys_t id o_wizard; /* VLCWizard */ id o_extended; /* VLCExtended */ id o_bookmarks; /* VLCBookmarks */ - id o_vlm; /* VLCVLMController */ id o_embedded_list; /* VLCEmbeddedList*/ id o_coredialogs; /* VLCCoreDialogProvider */ VLCInformation * o_info; /* VLCInformation */ @@ -119,7 +118,6 @@ struct intf_sys_t BOOL nib_prefs_loaded; /* preferences nibfile */ BOOL nib_update_loaded; /* update nibfile */ BOOL nib_info_loaded; /* information panel nibfile */ - BOOL nib_vlm_loaded; /* VLM Panel nibfile */ BOOL nib_coredialogs_loaded; /* CoreDialogs nibfile */ IBOutlet VLCControllerWindow * o_window; /* main window */ @@ -195,7 +193,6 @@ struct intf_sys_t IBOutlet NSMenuItem * o_mi_open_recent; IBOutlet NSMenuItem * o_mi_open_recent_cm; IBOutlet NSMenuItem * o_mi_open_wizard; - IBOutlet NSMenuItem * o_mi_open_vlm; IBOutlet NSMenu * o_mu_edit; IBOutlet NSMenuItem * o_mi_cut; @@ -391,7 +388,6 @@ struct intf_sys_t - (IBAction)intfOpenCapture:(id)sender; - (IBAction)showWizard:(id)sender; -- (IBAction)showVLM:(id)sender; - (IBAction)showExtended:(id)sender; - (IBAction)showBookmarks:(id)sender; diff --git a/modules/gui/macosx/intf.m b/modules/gui/macosx/intf.m index 6e4ad9ce63..725451ed11 100644 --- a/modules/gui/macosx/intf.m +++ b/modules/gui/macosx/intf.m @@ -54,7 +54,6 @@ #import "AppleRemote.h" #import "eyetv.h" #import "simple_prefs.h" -#import "vlm.h" #import /* for crashlog send mechanism */ #import /* for the media key support */ @@ -324,7 +323,6 @@ static VLCMain *_o_sharedMainInstance = nil; o_prefs = nil; o_open = [[VLCOpen alloc] init]; o_wizard = [[VLCWizard alloc] init]; - o_vlm = [[VLCVLMController alloc] init]; o_extended = nil; o_bookmarks = [[VLCBookmarks alloc] init]; o_embedded_list = [[VLCEmbeddedList alloc] init]; @@ -1421,11 +1419,6 @@ static unsigned int VLCModifiersToCocoa( unsigned int i_key ) return nil; } -- (id)vlm -{ - return o_vlm; -} - - (id)bookmarks { if( o_bookmarks ) @@ -2168,14 +2161,6 @@ end: } } -- (IBAction)showVLM:(id)sender -{ - if( !nib_vlm_loaded ) - nib_vlm_loaded = [NSBundle loadNibNamed:@"VLM" owner: NSApp]; - - [o_vlm showVLMWindow]; -} - - (IBAction)showExtended:(id)sender { if( o_extended == nil ) diff --git a/modules/gui/macosx/misc.m b/modules/gui/macosx/misc.m index 4d77a3824b..fe7b507756 100644 --- a/modules/gui/macosx/misc.m +++ b/modules/gui/macosx/misc.m @@ -91,7 +91,7 @@ @implementation NSAnimation (VLCAdditions) /* fake class attributes */ -static NSMapTable *VLCAdditions_userInfo = NULL; +static NSMapTable *VLCAdditions_userInfo = nil; + (void)load { @@ -124,7 +124,7 @@ static NSMapTable *VLCAdditions_userInfo = NULL; @implementation NSScreen (VLCAdditions) -static NSMutableArray *blackoutWindows = NULL; +static NSMutableArray *blackoutWindows = nil; + (void)load { @@ -132,6 +132,12 @@ static NSMutableArray *blackoutWindows = NULL; blackoutWindows = [[NSMutableArray alloc] initWithCapacity:1]; } +- (void)dealloc +{ + [blackoutWindows release]; + [super dealloc]; +} + + (NSScreen *)screenWithDisplayID: (CGDirectDisplayID)displayID { int i; diff --git a/modules/gui/macosx/simple_prefs.m b/modules/gui/macosx/simple_prefs.m index 30379244dd..debf9efd70 100644 --- a/modules/gui/macosx/simple_prefs.m +++ b/modules/gui/macosx/simple_prefs.m @@ -661,7 +661,11 @@ static inline void save_string_list( intf_thread_t * p_intf, id object, const ch p_item = config_FindConfig( VLC_OBJECT(p_intf), name ); p_stringobject = (NSString *)[[object selectedItem] representedObject]; assert([p_stringobject isKindOfClass:[NSString class]]); - if( p_stringobject ) config_PutPsz( p_intf, name, [p_stringobject UTF8String] ); + if( p_stringobject ) + { + config_PutPsz( p_intf, name, [p_stringobject UTF8String] ); + [p_stringobject release]; + } } static inline void save_module_list( intf_thread_t * p_intf, id object, const char * name ) @@ -694,7 +698,6 @@ static inline void save_module_list( intf_thread_t * p_intf, id object, const ch { char *psz_tmp; int i; - NSString *p_stringobject; #define SaveIntList( object, name ) save_int_list( p_intf, object, name ) diff --git a/modules/gui/macosx/vlm.h b/modules/gui/macosx/vlm.h deleted file mode 100644 index bbaeba74f9..0000000000 --- a/modules/gui/macosx/vlm.h +++ /dev/null @@ -1,115 +0,0 @@ -/***************************************************************************** - * vlm.h: VLM Configuration panel for Mac OS X - ***************************************************************************** - * Copyright (c) 2008 the VideoLAN team - * $Id$ - * - * Authors: Felix Paul Kühne - * - * 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 - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. - *****************************************************************************/ - - -#ifdef HAVE_CONFIG_H -# import "config.h" -#endif - -#ifdef ENABLE_VLM - -#import -#import "intf.h" - -#import - -@interface VLCVLMController : NSObject -{ - /* broadcast panel */ - IBOutlet NSButton *o_bcast_add_btn; - IBOutlet NSBox *o_bcast_box; - IBOutlet NSButton *o_bcast_cancel_btn; - IBOutlet NSButton *o_bcast_enable_ckb; - IBOutlet NSButton *o_bcast_input_btn; - IBOutlet NSTextField *o_bcast_input_fld; - IBOutlet NSButton *o_bcast_loop_ckb; - IBOutlet NSTextField *o_bcast_name_fld; - IBOutlet NSButton *o_bcast_output_btn; - IBOutlet NSTextField *o_bcast_output_fld; - IBOutlet NSPanel *o_bcast_panel; - - /* schedule panel */ - IBOutlet id o_sched_add_btn; - IBOutlet id o_sched_box; - IBOutlet id o_sched_cancel_btn; - IBOutlet NSDatePicker *o_sched_date_datePicker; - IBOutlet NSTextField *o_sched_date_lbl; - IBOutlet NSButton *o_sched_input_btn; - IBOutlet NSTextField *o_sched_input_fld; - IBOutlet NSTextField *o_sched_input_lbl; - IBOutlet NSTextField *o_sched_name_fld; - IBOutlet NSTextField *o_sched_name_lbl; - IBOutlet NSButton *o_sched_output_btn; - IBOutlet NSTextField *o_sched_output_fld; - IBOutlet NSTextField *o_sched_output_lbl; - IBOutlet NSTextField *o_sched_repeat_fld; - IBOutlet NSTextField *o_sched_repeat_lbl; - IBOutlet NSDatePicker *o_sched_repeatDelay_datePicker; - IBOutlet id o_sched_time_box; - IBOutlet NSWindow *o_sched_panel; - - /* VLM Window */ - IBOutlet NSTableView *o_vlm_list; - IBOutlet NSWindow *o_vlm_win; - - /* VOD Panel */ - IBOutlet NSButton *o_vod_add_btn; - IBOutlet id o_vod_box; - IBOutlet NSButton *o_vod_cancel_btn; - IBOutlet NSButton *o_vod_input_btn; - IBOutlet NSTextField *o_vod_input_fld; - IBOutlet NSTextField *o_vod_input_lbl; - IBOutlet NSButton *o_vod_loop_ckb; - IBOutlet NSTextField *o_vod_name_fld; - IBOutlet NSTextField *o_vod_name_lbl; - IBOutlet NSButton *o_vod_output_btn; - IBOutlet NSTextField *o_vod_output_fld; - IBOutlet NSTextField *o_vod_output_lbl; - IBOutlet NSWindow *o_vod_panel; -} -+ (VLCVLMController *)sharedInstance; - -/* toolbar */ -- (NSToolbarItem *) toolbar: (NSToolbar *)o_toolbar - itemForItemIdentifier: (NSString *)o_itemIdent - willBeInsertedIntoToolbar: (BOOL)b_willBeInserted; -- (NSArray *)toolbarDefaultItemIdentifiers: (NSToolbar *)toolbar; -- (NSArray *)toolbarAllowedItemIdentifiers: (NSToolbar *)toolbar; - -- (void)showVLMWindow; -- (void)initStrings; - -- (void)addBcast; -- (void)addVOD; -- (void)addSched; - -- (IBAction)bcastButtonAction:(id)sender; -- (IBAction)listDoubleClickAction:(id)sender; -- (IBAction)schedButtonAction:(id)sender; -- (IBAction)vodButtonAction:(id)sender; - -- (int)numberOfRowsInTableView:(NSTableView *)aTableView; -- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex; -@end - -#endif \ No newline at end of file diff --git a/modules/gui/macosx/vlm.m b/modules/gui/macosx/vlm.m deleted file mode 100644 index c66beb03cc..0000000000 --- a/modules/gui/macosx/vlm.m +++ /dev/null @@ -1,184 +0,0 @@ -/***************************************************************************** - * vlm.m: VLM Configuration panel for Mac OS X - ***************************************************************************** - * Copyright (c) 2008 the VideoLAN team - * $Id$ - * - * Authors: Felix Paul Kühne - * - * 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 - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. - *****************************************************************************/ - -#import "vlm.h" - -#ifdef ENABLE_VLM - -static NSString * VLCVLMToolbarIdentifier = @"Our VLM Toolbar Identifier"; -static NSString * VLCVODToolbarIdentifier = @"VLM Item"; -static NSString * VLCSchedToolbarIdentifier = @"Sched Item"; -static NSString * VLCBcastToolbarIdentifier = @"Bcast Item"; - -@implementation VLCVLMController - -static VLCVLMController *_o_sharedInstance = nil; - -+ (VLCVLMController *)sharedInstance -{ - return _o_sharedInstance ? _o_sharedInstance : [[self alloc] init]; -} - -- (id)init -{ - if( _o_sharedInstance ) - [self dealloc]; - else - { - _o_sharedInstance = [super init]; - } - - return _o_sharedInstance; -} - -- (void)awakeFromNib -{ - [self initStrings]; - - /* setup the toolbar */ - NSToolbar * o_vlm_toolbar = [[[NSToolbar alloc] initWithIdentifier: VLCVLMToolbarIdentifier] autorelease]; - [o_vlm_toolbar setAllowsUserCustomization: NO]; - [o_vlm_toolbar setAutosavesConfiguration: NO]; - [o_vlm_toolbar setDisplayMode: NSToolbarDisplayModeIconAndLabel]; - [o_vlm_toolbar setSizeMode: NSToolbarSizeModeRegular]; - [o_vlm_toolbar setDelegate: self]; - [o_vlm_win setToolbar: o_vlm_toolbar]; -} - -#define CreateToolbarItem( o_name, o_desc, o_img, sel ) \ - o_toolbarItem = create_toolbar_item(o_itemIdent, o_name, o_desc, o_img, self, @selector(sel)); -static inline NSToolbarItem * -create_toolbar_item( NSString * o_itemIdent, NSString * o_name, NSString * o_desc, NSString * o_img, id target, SEL selector ) -{ - NSToolbarItem *o_toolbarItem = [[[NSToolbarItem alloc] initWithItemIdentifier: o_itemIdent] autorelease]; \ - - [o_toolbarItem setLabel: o_name]; - [o_toolbarItem setPaletteLabel: o_desc]; - - [o_toolbarItem setToolTip: o_desc]; - [o_toolbarItem setImage: [NSImage imageNamed: o_img]]; - - [o_toolbarItem setTarget: target]; - [o_toolbarItem setAction: selector]; - - [o_toolbarItem setEnabled: YES]; - [o_toolbarItem setAutovalidates: YES]; - - return o_toolbarItem; -} - -- (NSToolbarItem *) toolbar: (NSToolbar *)o_vlm_toolbar - itemForItemIdentifier: (NSString *)o_itemIdent - willBeInsertedIntoToolbar: (BOOL)b_willBeInserted -{ - NSToolbarItem *o_toolbarItem = nil; - - if( [o_itemIdent isEqual: VLCVODToolbarIdentifier] ) - { - CreateToolbarItem( _NS("Video On Demand"), _NS("Video On Demand"), @"add_vod", addVOD ); - } - else if( [o_itemIdent isEqual: VLCSchedToolbarIdentifier] ) - { - CreateToolbarItem( _NS("Schedule"), _NS("Schedule"), @"add_schedule", addSched ); - } - else if( [o_itemIdent isEqual: VLCBcastToolbarIdentifier] ) - { - CreateToolbarItem( _NS("Broadcast"), _NS("Broadcast"), @"add_broadcast", addBcast ); - } - - return o_toolbarItem; -} - -- (NSArray *)toolbarDefaultItemIdentifiers: (NSToolbar *)toolbar -{ - return [NSArray arrayWithObjects: VLCBcastToolbarIdentifier, VLCSchedToolbarIdentifier, VLCVODToolbarIdentifier, NSToolbarFlexibleSpaceItemIdentifier, nil]; -} - -- (NSArray *)toolbarAllowedItemIdentifiers: (NSToolbar *)toolbar -{ - return [NSArray arrayWithObjects: VLCBcastToolbarIdentifier, VLCSchedToolbarIdentifier, VLCVODToolbarIdentifier, NSToolbarFlexibleSpaceItemIdentifier, nil]; -} - -- (void)initStrings -{ - /* not implemented */ -} - -- (void)showVLMWindow -{ - [o_vlm_win makeKeyAndOrderFront: self]; -} - -- (void)addBcast -{ - [NSApp beginSheet: o_bcast_panel modalForWindow: o_vlm_win - modalDelegate: self didEndSelector: nil contextInfo: nil]; -} - -- (void)addVOD -{ - [NSApp beginSheet: o_vod_panel modalForWindow: o_vlm_win - modalDelegate: self didEndSelector: nil contextInfo: nil]; -} - -- (void)addSched -{ - [NSApp beginSheet: o_sched_panel modalForWindow: o_vlm_win - modalDelegate: self didEndSelector: nil contextInfo: nil]; -} - -- (IBAction)bcastButtonAction:(id)sender -{ - [NSApp endSheet: o_bcast_panel]; - [o_bcast_panel close]; -} - -- (IBAction)listDoubleClickAction:(id)sender -{ -} - -- (IBAction)schedButtonAction:(id)sender -{ - [NSApp endSheet: o_sched_panel]; - [o_sched_panel close]; -} - -- (IBAction)vodButtonAction:(id)sender -{ - [NSApp endSheet: o_vod_panel]; - [o_vod_panel close]; -} - -- (int)numberOfRowsInTableView:(NSTableView *)aTableView -{ - return 0; -} - -- (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex -{ - return @"dummy"; -} - -@end - -#endif \ No newline at end of file diff --git a/projects/mozilla/vlcshell.cpp b/projects/mozilla/vlcshell.cpp index e0b937bf23..151c615a18 100644 --- a/projects/mozilla/vlcshell.cpp +++ b/projects/mozilla/vlcshell.cpp @@ -387,6 +387,12 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) { /* check if plugin has a new parent window */ CGrafPtr drawable = (((NP_Port*) (window->window))->port); + if( !curwin.window || drawable != (((NP_Port*) (curwin.window))->port) ) + { + /* set/change parent window */ + libvlc_video_set_parent(p_vlc, (libvlc_drawable_t)drawable, &ex); + libvlc_exception_clear(&ex); + } /* as MacOS X video output is windowless, set viewport */ libvlc_rectangle_t view, clip; @@ -416,6 +422,9 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) else if( curwin.window ) { /* change/set parent */ + libvlc_video_set_parent(p_vlc, 0, &ex); + libvlc_exception_clear(&ex); + curwin.window = NULL; } #endif /* XP_MACOSX */ @@ -448,6 +457,10 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) style |= WS_CLIPCHILDREN|WS_CLIPSIBLINGS; SetWindowLong((HWND)drawable, GWL_STYLE, style); + /* change/set parent */ + libvlc_video_set_parent(p_vlc, (libvlc_drawable_t)drawable, &ex); + libvlc_exception_clear(&ex); + /* remember new window */ p_plugin->setWindow(*window); @@ -463,6 +476,10 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) SetWindowLong( oldwin, GWL_WNDPROC, (LONG)(p_plugin->getWindowProc()) ); p_plugin->setWindowProc(NULL); + /* change/set parent */ + libvlc_video_set_parent(p_vlc, 0, &ex); + libvlc_exception_clear(&ex); + curwin.window = NULL; } #endif /* XP_WIN */ @@ -512,6 +529,10 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) XtAddEventHandler( w, ButtonReleaseMask, FALSE, (XtEventHandler)ControlHandler, p_plugin ); + /* set/change parent window */ + libvlc_video_set_parent( p_vlc, (libvlc_drawable_t) video, &ex ); + libvlc_exception_clear(&ex); + /* remember window */ p_plugin->setWindow( *window ); p_plugin->setVideoWindow( video ); @@ -532,6 +553,9 @@ NPError NPP_SetWindow( NPP instance, NPWindow* window ) } else if( curwin.window ) { + /* change/set parent */ + libvlc_video_set_parent(p_vlc, 0, &ex); + libvlc_exception_clear(&ex); curwin.window = NULL; } #endif /* XP_UNIX */ diff --git a/src/modules/modules.c b/src/modules/modules.c index 0be6764f53..b4a1ca3c2e 100644 --- a/src/modules/modules.c +++ b/src/modules/modules.c @@ -172,7 +172,8 @@ void module_EndBank( vlc_object_t *p_this, bool b_plugins ) assert (p_bank != NULL); /* Save the configuration */ - config_AutoSaveConfigFile( p_this ); + if( !config_GetInt( p_this, "ignore-config" ) ) + config_AutoSaveConfigFile( p_this ); /* If plugins were _not_ loaded, then the caller still has the bank lock * from module_InitBank(). */