OUTLETS = {
"o_btn_cancel" = id;
"o_btn_ok" = id;
- "o_ckbox_enqueue" = id;
"o_disc_chapter" = id;
"o_disc_chapter_lbl" = id;
"o_disc_chapter_stp" = id;
<integer>977</integer>
</array>
<key>IBSystem Version</key>
- <string>6L60</string>
+ <string>6R73</string>
</dict>
</plist>
* codecs.h: codec related structures needed by the demuxers and decoders
*****************************************************************************
* Copyright (C) 1999-2001 VideoLAN
- * $Id: codecs.h,v 1.5 2003/08/18 00:17:44 fenrir Exp $
+ * $Id: codecs.h,v 1.6 2003/10/19 23:12:16 hartman Exp $
*
* Authors: Gildas Bazin <gbazin@netcourrier.com>
*
/* WAVE form wFormatTag IDs */
-#define WAVE_FORMAT_UNKNOWN 0x0000 /* Microsoft Corporation */
-#define WAVE_FORMAT_PCM 0x0001 /* Microsoft Corporation */
-#define WAVE_FORMAT_ADPCM 0x0002 /* Microsoft Corporation */
-#define WAVE_FORMAT_IEEE_FLOAT 0x0003 /* Microsoft Corporation */
-#define WAVE_FORMAT_ALAW 0x0006 /* Microsoft Corporation */
-#define WAVE_FORMAT_MULAW 0x0007 /* Microsoft Corporation */
-#define WAVE_FORMAT_DTS 0x0008 /* Microsoft Corporation */
-#define WAVE_FORMAT_IMA_ADPCM 0x0011
-#define WAVE_FORMAT_MPEG 0x0050 /* Microsoft Corporation */
-#define WAVE_FORMAT_MPEGLAYER3 0x0055 /* ISO/MPEG Layer3 Format Tag */
-#define WAVE_FORMAT_DOLBY_AC3_SPDIF 0x0092 /* Sonic Foundry */
+#define WAVE_FORMAT_UNKNOWN 0x0000 /* Microsoft Corporation */
+#define WAVE_FORMAT_PCM 0x0001 /* Microsoft Corporation */
+#define WAVE_FORMAT_ADPCM 0x0002 /* Microsoft Corporation */
+#define WAVE_FORMAT_IEEE_FLOAT 0x0003 /* Microsoft Corporation */
+#define WAVE_FORMAT_ALAW 0x0006 /* Microsoft Corporation */
+#define WAVE_FORMAT_MULAW 0x0007 /* Microsoft Corporation */
+#define WAVE_FORMAT_DTS 0x0008 /* Microsoft Corporation */
+#define WAVE_FORMAT_IMA_ADPCM 0x0011 /* Intel Corporation */
+#define WAVE_FORMAT_GSM610 0x0031 /* Microsoft Corporation */
+#define WAVE_FORMAT_MSNAUDIO 0x0032 /* Microsoft Corporation */
+#define WAVE_FORMAT_MPEG 0x0050 /* Microsoft Corporation */
+#define WAVE_FORMAT_MPEGLAYER3 0x0055 /* ISO/MPEG Layer3 Format Tag */
+#define WAVE_FORMAT_DOLBY_AC3_SPDIF 0x0092 /* Sonic Foundry */
-#define WAVE_FORMAT_A52 0x2000
-#define WAVE_FORMAT_WMA1 0x0160
-#define WAVE_FORMAT_WMA2 0x0161
-#define WAVE_FORMAT_WMA3 0x0162
+#define WAVE_FORMAT_A52 0x2000
+#define WAVE_FORMAT_WMA1 0x0160
+#define WAVE_FORMAT_WMA2 0x0161
+#define WAVE_FORMAT_WMA3 0x0162
/* Need to check these */
-#define WAVE_FORMAT_DK3 0x0061
-#define WAVE_FORMAT_DK4 0x0061
+#define WAVE_FORMAT_DK3 0x0061
+#define WAVE_FORMAT_DK4 0x0062
#if !defined(WAVE_FORMAT_EXTENSIBLE)
-#define WAVE_FORMAT_EXTENSIBLE 0xFFFE /* Microsoft */
+#define WAVE_FORMAT_EXTENSIBLE 0xFFFE /* Microsoft */
#endif
static struct
* open.h: MacOS X plugin for vlc
*****************************************************************************
* Copyright (C) 2002-2003 VideoLAN
- * $Id: open.h,v 1.15 2003/07/27 23:05:41 hartman Exp $
+ * $Id: open.h,v 1.16 2003/10/19 23:12:16 hartman Exp $
*
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr>
IBOutlet id o_btn_ok;
IBOutlet id o_btn_cancel;
- IBOutlet id o_ckbox_enqueue;
IBOutlet id o_file_path;
IBOutlet id o_file_btn_browse;
* open.m: MacOS X plugin for vlc
*****************************************************************************
* Copyright (C) 2002-2003 VideoLAN
- * $Id: open.m,v 1.38 2003/09/19 23:03:27 hartman Exp $
+ * $Id: open.m,v 1.39 2003/10/19 23:12:16 hartman Exp $
*
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr>
[o_panel setTitle: _NS("Open Source")];
[o_mrl_lbl setTitle: _NS("Media Resource Locator (MRL)")];
- [o_ckbox_enqueue setTitle: _NS("Only enqueue in playlist, do not play")];
[o_btn_ok setTitle: _NS("OK")];
[o_btn_cancel setTitle: _NS("Cancel")];
{
NSMutableDictionary *o_dic;
NSMutableArray *o_options = [NSMutableArray array];
- BOOL b_enq = [o_ckbox_enqueue state] == NSOnState ? YES : NO;
o_dic = [NSMutableDictionary dictionaryWithObject: [o_mrl stringValue] forKey: @"ITEM_URL"];
if( [o_file_sub_ckbox state] == NSOnState )
[o_options addObject: [NSString stringWithFormat: @"sout=%@", [(VLCOutput *)o_sout_options getMRL]]];
}
[o_dic setObject: (NSArray *)[o_options copy] forKey: @"ITEM_OPTIONS"];
- [o_playlist appendArray: [NSArray arrayWithObject: o_dic] atPos: -1 enqueue:b_enq];
+ [o_playlist appendArray: [NSArray arrayWithObject: o_dic] atPos: -1 enqueue:NO];
}
}
* playlist.m: MacOS X interface plugin
*****************************************************************************
* Copyright (C) 2002-2003 VideoLAN
- * $Id: playlist.m,v 1.33 2003/09/22 03:40:05 hartman Exp $
+ * $Id: playlist.m,v 1.34 2003/10/19 23:12:16 hartman Exp $
*
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Derk-Jan Hartman <thedj@users.sourceforge.net>
#include <sys/param.h> /* for MAXPATHLEN */
#include <string.h>
#include <math.h>
+#include <sys/mount.h>
#include "intf.h"
#include "playlist.h"
{
/* One item */
NSDictionary *o_one_item;
- NSString *o_url;
- NSString *o_name;
+ int j;
+ int i_total_options = 0;
+ int i_mode = PLAYLIST_INSERT;
+ BOOL b_rem = FALSE, b_dir = FALSE;
+ NSString *o_url, *o_name;
NSArray *o_options;
- int j, i_total_options = 0;
char **ppsz_options = NULL;
- int i_mode = PLAYLIST_INSERT;
-
+
/* Get the item */
o_one_item = [o_array objectAtIndex: i_item];
o_url = (NSString *)[o_one_item objectForKey: @"ITEM_URL"];
o_name = (NSString *)[o_one_item objectForKey: @"ITEM_NAME"];
o_options = (NSArray *)[o_one_item objectForKey: @"ITEM_OPTIONS"];
- if( !o_name) o_name = o_url;
-
+ /* If no name, then make a guess */
+ if( !o_name) o_name = [[NSFileManager defaultManager] displayNameAtPath: o_url];
+
+ if( [[NSFileManager defaultManager] fileExistsAtPath:o_url isDirectory:&b_dir] && b_dir &&
+ [[NSWorkspace sharedWorkspace] getFileSystemInfoForPath: o_url isRemovable: &b_rem
+ isWritable:NULL isUnmountable:NULL description:NULL type:NULL] && b_rem )
+ {
+ /* All of this is to make sure CD's play when you D&D them on VLC */
+ /* Converts mountpoint to a /dev file */
+ struct statfs *buf;
+ char *psz_dev, *temp;
+ buf = (struct statfs *) malloc (sizeof(struct statfs));
+ statfs( [o_url fileSystemRepresentation], buf );
+ psz_dev = strdup(buf->f_mntfromname);
+ free( buf );
+ temp = strrchr( psz_dev , 's' );
+ psz_dev[temp - psz_dev] = '\0';
+ o_url = [NSString stringWithCString: psz_dev ];
+ NSLog(@"%@", o_url);
+ }
+
if (i_item == 0 && !b_enqueue)
i_mode |= PLAYLIST_GO;
-
+
if( o_options && [o_options count] > 0 )
{
/* Count the input options */
ppsz_options[j] = strdup([[o_options objectAtIndex:j] UTF8String]);
}
}
-
- playlist_AddExt( p_playlist, [o_name UTF8String], [o_url fileSystemRepresentation], -1,
+
+ playlist_AddExt( p_playlist, [o_url fileSystemRepresentation], [o_name UTF8String], -1,
(ppsz_options != NULL ) ? (const char **)ppsz_options : 0, i_total_options,
- i_mode, i_position == -1 ? PLAYLIST_END : i_position + i_item );
-
+ i_mode, i_position == -1 ? PLAYLIST_END : i_position + i_item);
+
/* clean up */
for( j = 0; j < i_total_options; j++ )
free( ppsz_options[j] );
if( ppsz_options ) free( ppsz_options );
-
+
+ /* Recent documents menu */
NSURL *o_true_url = [NSURL fileURLWithPath: o_url];
if( o_true_url != nil )
{
return;
}
- vlc_mutex_lock( &p_playlist->object_lock );
i_row = p_playlist->i_index;
- vlc_mutex_unlock( &p_playlist->object_lock );
vlc_object_release( p_playlist );
[o_table_view selectRow: i_row byExtendingSelection: NO];
o_array = [o_array arrayByAddingObject: o_dic];
}
[self appendArray: o_array atPos: i_proposed_row enqueue:YES];
-
- return( YES );
+ return YES;
}
-
- return( NO );
+ return NO;
}
[self updateRowSelection];
}