Commit 54ee50f3 authored by bigben's avatar bigben
Browse files

Also update the wizard playlist on item addition and deletion. This prevent...

Also update the wizard playlist on item addition and deletion. This prevent VLC to crash upon item deletion with the wizard open.

parent 00101866
......@@ -261,6 +261,7 @@ struct intf_sys_t
- (id)getControls;
- (id)getPlaylist;
- (id)getInfo;
- (id)getWizard;
- (void)terminate;
- (NSString *)localizedString:(char *)psz;
- (char *)delocalizeString:(NSString *)psz;
......
......@@ -764,7 +764,16 @@ static VLCMain *_o_sharedMainInstance = nil;
{
return o_info;
}
return nil;
return nil;
}
- (id)getWizard
{
if ( o_wizard )
{
return o_wizard;
}
return nil;
}
- (void)manage
......
......@@ -67,6 +67,7 @@
@interface VLCPlaylist : VLCPlaylistCommon
{
IBOutlet id o_controller;
IBOutlet id o_playlist_wizard;
IBOutlet id o_btn_playlist;
IBOutlet id o_playlist_view;
......
......@@ -335,7 +335,12 @@
- (IBAction)reloadOutlineView
{
[o_outline_view reloadData];
/* Only reload the outlineview if the wizard window is open since this can
be quite long on big playlists */
if( [[o_outline_view window] isVisible] )
{
[o_outline_view reloadData];
}
}
@end
......@@ -512,6 +517,7 @@ belongs to an Apple hidden private API, and then can "disapear" at any time*/
// TODO Find a way to keep the dict size to a minimum
//[o_outline_dict removeAllObjects];
[o_outline_view reloadData];
[[[[VLCMain sharedInstance] getWizard] getPlaylistWizard] reloadOutlineView];
}
- (void)playModeUpdated
......
......@@ -171,4 +171,6 @@
- (void)showSummary;
- (void)resetWizard;
- (void)createOpts;
- (id)getPlaylistWizard;
@end
......@@ -470,6 +470,11 @@ static VLCWizard *_o_sharedInstance = nil;
[o_wizard_window close];
}
- (id)getPlaylistWizard
{
return o_playlist_wizard;
}
- (IBAction)nextTab:(id)sender
{
if ([[[o_tab_pageHolder selectedTabViewItem] label] isEqualToString: @"Hello"])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment