/*****************************************************************************
* intf.m: MacOS X interface module
*****************************************************************************
- * Copyright (C) 2002-2005 VideoLAN (Centrale Réseaux) and its contributors
+ * Copyright (C) 2002-2005 the VideoLAN team
* $Id$
*
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
#include "about.h"
#include "open.h"
#include "wizard.h"
+#include "extended.h"
/*****************************************************************************
* Local prototypes.
o_prefs = nil;
o_open = [[VLCOpen alloc] init];
o_wizard = [[VLCWizard alloc] init];
+ o_extended = [[VLCExtended alloc] init];
i_lastShownVolume = -1;
return _o_sharedMainInstance;
[o_msgs_btn_crashlog setTitle: _NS("Open CrashLog")];
/* main menu */
- [o_mi_about setTitle: _NS("About VLC media player")];
+ [o_mi_about setTitle: _NS("About VLC media player...")];
[o_mi_prefs setTitle: _NS("Preferences...")];
[o_mi_add_intf setTitle: _NS("Add Interface")];
[o_mu_add_intf setTitle: _NS("Add Interface")];
[o_mi_close_window setTitle: _NS("Close Window")];
[o_mi_controller setTitle: _NS("Controller")];
[o_mi_equalizer setTitle: _NS("Equalizer")];
+ [o_mi_extended setTitle: _NS("Extended controls")];
[o_mi_playlist setTitle: _NS("Playlist")];
[o_mi_info setTitle: _NS("Info")];
[o_mi_messages setTitle: _NS("Messages")];
case NSDeleteFunctionKey:
case NSDeleteCharFunctionKey:
case NSBackspaceCharacter:
- return YES;
case NSUpArrowFunctionKey:
case NSDownArrowFunctionKey:
case NSRightArrowFunctionKey:
{
return o_info;
}
- return nil;
+ return nil;
+}
+
+- (id)getWizard
+{
+ if ( o_wizard )
+ {
+ return o_wizard;
+ }
+ return nil;
}
- (void)manage
if( p_intf->p_sys->b_volume_update )
{
NSString *o_text;
- o_text = [NSString stringWithFormat: _NS("Volume: %d"), i_lastShownVolume * 200 / AOUT_VOLUME_MAX];
+ o_text = [NSString stringWithFormat: _NS("Volume: %d%%"), i_lastShownVolume * 400 / AOUT_VOLUME_MAX];
if( i_lastShownVolume != -1 )
[self setScrollField:o_text stopAfter:1000000];
playlist_t * p_playlist;
vout_thread_t * p_vout;
+#define p_input p_intf->p_sys->p_input
+ if( p_input )
+ {
+ vlc_object_release( p_input );
+ p_input = NULL;
+ }
+#undef p_input
+
/* Stop playback */
if( ( p_playlist = vlc_object_find( p_intf, VLC_OBJECT_PLAYLIST,
FIND_ANYWHERE ) ) )
}
}
+- (IBAction)showExtended:(id)sender
+{
+ if (!nib_extended_loaded)
+ {
+ nib_extended_loaded = [NSBundle loadNibNamed:@"Extended" owner:self];
+ [o_extended initStrings];
+ [o_extended showPanel];
+ } else {
+ [o_extended showPanel];
+ }
+}
+
- (IBAction)viewAbout:(id)sender
{
- [o_about showPanel];
+ if (!nib_about_loaded)
+ {
+ nib_about_loaded = [NSBundle loadNibNamed:@"About" owner:self];
+ [o_about showPanel];
+ } else {
+ [o_about showPanel];
+ }
}
- (IBAction)viewPreferences:(id)sender