Commit 9d8a2d05 authored by Derk-Jan Hartman's avatar Derk-Jan Hartman

* First set config variable, then add the files (and therefore potentially

  play them) in the playlist. Otherwise we can be too late.
parent cfbae214
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* intf.m: MacOS X interface plugin * intf.m: MacOS X interface plugin
***************************************************************************** *****************************************************************************
* Copyright (C) 2002-2003 VideoLAN * Copyright (C) 2002-2003 VideoLAN
* $Id: intf.m,v 1.81 2003/05/11 23:17:30 hartman Exp $ * $Id: intf.m,v 1.82 2003/05/12 01:17:10 hartman Exp $
* *
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net> * Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr> * Christophe Massiot <massiot@via.ecp.fr>
...@@ -429,13 +429,13 @@ int ExecuteOnMainThread( id target, SEL sel, void * p_arg ) ...@@ -429,13 +429,13 @@ int ExecuteOnMainThread( id target, SEL sel, void * p_arg )
{ {
intf_thread_t * p_intf = [NSApp getIntf]; intf_thread_t * p_intf = [NSApp getIntf];
[o_playlist appendArray: config_PutPsz( p_intf, "sub-file", "" );
[NSArray arrayWithObject: o_filename] atPos: -1 enqueue: NO];
config_PutPsz( [NSApp getIntf], "sub-file", "" );
config_PutInt( p_intf, "sub-delay", 0 ); config_PutInt( p_intf, "sub-delay", 0 );
config_PutFloat( p_intf, "sub-fps", 0.0 ); config_PutFloat( p_intf, "sub-fps", 0.0 );
config_PutPsz( p_intf, "sout", "" ); config_PutPsz( p_intf, "sout", "" );
[o_playlist appendArray:
[NSArray arrayWithObject: o_filename] atPos: -1 enqueue: NO];
return( TRUE ); return( TRUE );
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* open.m: MacOS X plugin for vlc * open.m: MacOS X plugin for vlc
***************************************************************************** *****************************************************************************
* Copyright (C) 2002-2003 VideoLAN * Copyright (C) 2002-2003 VideoLAN
* $Id: open.m,v 1.32 2003/05/08 17:13:22 massiot Exp $ * $Id: open.m,v 1.33 2003/05/12 01:17:10 hartman Exp $
* *
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net> * Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr> * Christophe Massiot <massiot@via.ecp.fr>
...@@ -235,9 +235,6 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class ) ...@@ -235,9 +235,6 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class )
BOOL b_enq = [o_ckbox_enqueue state] == NSOnState ? YES : NO; BOOL b_enq = [o_ckbox_enqueue state] == NSOnState ? YES : NO;
NSString *subPath = [o_file_sub_path stringValue]; NSString *subPath = [o_file_sub_path stringValue];
[o_playlist appendArray:
[NSArray arrayWithObject: o_source] atPos: -1 enqueue:b_enq];
if (([o_file_sub_ckbox state] == NSOnState) && !([subPath isEqualTo: @""])) if (([o_file_sub_ckbox state] == NSOnState) && !([subPath isEqualTo: @""]))
{ {
config_PutPsz( p_intf, "sub-file", strdup( [subPath cString] ) ); config_PutPsz( p_intf, "sub-file", strdup( [subPath cString] ) );
...@@ -253,6 +250,9 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class ) ...@@ -253,6 +250,9 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class )
config_PutInt( p_intf, "sub-delay", 0 ); config_PutInt( p_intf, "sub-delay", 0 );
config_PutFloat( p_intf, "sub-fps", 0.0 ); config_PutFloat( p_intf, "sub-fps", 0.0 );
} }
[o_playlist appendArray:
[NSArray arrayWithObject: o_source] atPos: -1 enqueue:b_enq];
} }
} }
...@@ -623,11 +623,12 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class ) ...@@ -623,11 +623,12 @@ NSArray *GetEjectableMediaOfClass( const char *psz_class )
NSArray *o_values = [[o_open_panel filenames] NSArray *o_values = [[o_open_panel filenames]
sortedArrayUsingSelector:@selector(caseInsensitiveCompare:)]; sortedArrayUsingSelector:@selector(caseInsensitiveCompare:)];
[o_playlist appendArray: o_values atPos: -1 enqueue:NO];
config_PutPsz( p_intf, "sub-file", "" ); config_PutPsz( p_intf, "sub-file", "" );
config_PutInt( p_intf, "sub-delay", 0 ); config_PutInt( p_intf, "sub-delay", 0 );
config_PutFloat( p_intf, "sub-fps", 0.0 ); config_PutFloat( p_intf, "sub-fps", 0.0 );
config_PutPsz( p_intf, "sout", "" ); config_PutPsz( p_intf, "sout", "" );
[o_playlist appendArray: o_values atPos: -1 enqueue:NO];
} }
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* playlist.m: MacOS X interface plugin * playlist.m: MacOS X interface plugin
***************************************************************************** *****************************************************************************
* Copyright (C) 2002-2003 VideoLAN * Copyright (C) 2002-2003 VideoLAN
* $Id: playlist.m,v 1.21 2003/04/29 20:17:12 hartman Exp $ * $Id: playlist.m,v 1.22 2003/05/12 01:17:10 hartman Exp $
* *
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net> * Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Derk-Jan Hartman <thedj@users.sourceforge.net> * Derk-Jan Hartman <thedj@users.sourceforge.net>
...@@ -450,13 +450,14 @@ ...@@ -450,13 +450,14 @@
{ {
o_values = [[o_pasteboard propertyListForType: NSFilenamesPboardType] o_values = [[o_pasteboard propertyListForType: NSFilenamesPboardType]
sortedArrayUsingSelector:@selector(caseInsensitiveCompare:)]; sortedArrayUsingSelector:@selector(caseInsensitiveCompare:)];
[self appendArray: o_values atPos: i_proposed_row enqueue:YES];
config_PutPsz( p_intf, "sub-file", "" ); config_PutPsz( p_intf, "sub-file", "" );
config_PutInt( p_intf, "sub-delay", 0 ); config_PutInt( p_intf, "sub-delay", 0 );
config_PutFloat( p_intf, "sub-fps", 0.0 ); config_PutFloat( p_intf, "sub-fps", 0.0 );
config_PutPsz( p_intf, "sout", "" ); config_PutPsz( p_intf, "sout", "" );
[self appendArray: o_values atPos: i_proposed_row enqueue:YES];
return( YES ); return( YES );
} }
......
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