Commit 358e35e7 authored by Felix Paul Kühne's avatar Felix Paul Kühne

macosx: added a non-implemented skeletion (just the UI) for a VLM...

macosx: added a non-implemented skeletion (just the UI) for a VLM configuration panel with a preliminary icon set
parent 6e41ca01
......@@ -2,8 +2,19 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IBDocumentLocation</key>
<string>69 71 356 240 0 0 1280 778 </string>
<key>IBEditorPositions</key>
<dict>
<key>29</key>
<string>69 317 438 44 0 0 1280 778 </string>
<key>3568</key>
<string>476 534 328 85 0 0 1280 778 </string>
<key>915</key>
<string>69 316 187 308 0 0 1280 778 </string>
</dict>
<key>IBFramework Version</key>
<string>649</string>
<string>489.0</string>
<key>IBLastKnownRelativeProjectPath</key>
<string>../../vlc.xcodeproj</string>
<key>IBOldestOS</key>
......@@ -11,10 +22,10 @@
<key>IBOpenObjects</key>
<array>
<integer>3706</integer>
<integer>21</integer>
<integer>29</integer>
<integer>3568</integer>
<integer>915</integer>
<integer>21</integer>
<integer>29</integer>
</array>
<key>IBSystem Version</key>
<string>9E17</string>
......
{
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
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IBDocumentLocation</key>
<string>609 119 356 240 0 0 1280 778 </string>
<key>IBFramework Version</key>
<string>489.0</string>
<key>IBOpenObjects</key>
<array>
<integer>5</integer>
<integer>106</integer>
<integer>65</integer>
<integer>30</integer>
</array>
<key>IBSystem Version</key>
<string>9E17</string>
</dict>
</plist>
......@@ -154,6 +154,10 @@
CC402F420E00ABBB006A4BA4 /* ApplicationServices.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CC3DC89B0A7CDB9600B53F32 /* ApplicationServices.framework */; };
CC402F430E00ABBB006A4BA4 /* QTKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CC1941240B9C1F8400635F6B /* QTKit.framework */; };
CC402F440E00ABBB006A4BA4 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CC962E2C0CC7992800A56695 /* WebKit.framework */; };
CCB60A420E6E5E3F00407004 /* VLM.nib in Resources */ = {isa = PBXBuildFile; fileRef = CCB60A400E6E5E3F00407004 /* VLM.nib */; };
CCD90F4E0E87C86D0034564A /* add_schedule.png in Resources */ = {isa = PBXBuildFile; fileRef = CCD90F4B0E87C86D0034564A /* add_schedule.png */; };
CCD90F4F0E87C86D0034564A /* add_vod.png in Resources */ = {isa = PBXBuildFile; fileRef = CCD90F4C0E87C86D0034564A /* add_vod.png */; };
CCD90F500E87C86D0034564A /* add_broadcast.png in Resources */ = {isa = PBXBuildFile; fileRef = CCD90F4D0E87C86D0034564A /* add_broadcast.png */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
......@@ -319,6 +323,9 @@
CC965D5F0DA5880F0088F222 /* display_right.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = display_right.png; path = Resources/display_right.png; sourceTree = "<group>"; };
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 = "<group>"; };
CCC593780AB4A9FB0004FF52 /* embeddedwindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = embeddedwindow.h; path = ../../../modules/gui/macosx/embeddedwindow.h; sourceTree = SOURCE_ROOT; };
CCC593790AB4A9FB0004FF52 /* embeddedwindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = embeddedwindow.m; path = ../../../modules/gui/macosx/embeddedwindow.m; sourceTree = SOURCE_ROOT; };
CCC895830D9A8A82005AE59C /* eyetv.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = eyetv.m; path = ../../../modules/access/eyetv.m; sourceTree = SOURCE_ROOT; };
......@@ -350,6 +357,9 @@
CCCB86D80ACFDFB300CF1E10 /* fs_stop_highlight.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = fs_stop_highlight.png; path = Resources/fs_stop_highlight.png; sourceTree = "<group>"; };
CCCB86D90ACFDFB300CF1E10 /* fs_stop.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = fs_stop.png; path = Resources/fs_stop.png; sourceTree = "<group>"; };
CCCB86DA0ACFDFB300CF1E10 /* fs_background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = fs_background.png; path = Resources/fs_background.png; sourceTree = "<group>"; };
CCD90F4B0E87C86D0034564A /* add_schedule.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = add_schedule.png; path = Resources/add_schedule.png; sourceTree = "<group>"; };
CCD90F4C0E87C86D0034564A /* add_vod.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = add_vod.png; path = Resources/add_vod.png; sourceTree = "<group>"; };
CCD90F4D0E87C86D0034564A /* add_broadcast.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = add_broadcast.png; path = Resources/add_broadcast.png; sourceTree = "<group>"; };
DC769AB7085DF0DB001A838D /* wizard.m */ = {isa = PBXFileReference; fileEncoding = 5; indentWidth = 4; lastKnownFileType = sourcecode.c.objc; name = wizard.m; path = ../../../modules/gui/macosx/wizard.m; sourceTree = SOURCE_ROOT; tabWidth = 4; usesTabs = 0; };
DC769AB8085DF0DB001A838D /* wizard.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; name = wizard.h; path = ../../../modules/gui/macosx/wizard.h; sourceTree = SOURCE_ROOT; };
DC7F46EC08A183FC0027DB24 /* English */ = {isa = PBXFileReference; lastKnownFileType = wrapper.nib; name = English; path = Resources/English.lproj/Extended.nib; sourceTree = "<group>"; };
......@@ -422,6 +432,7 @@
F69B0CA602E24F6401A80112 /* InfoPlist.strings */,
8EBF3FA303F13FFB0059A3A7 /* vlc.scriptSuite */,
CC1C41D00D9BAD7F002728FA /* noart.png */,
CCD90F4A0E87C82D0034564A /* VLM */,
CC0B71E00D54F0DD00448E00 /* simple prefs (taken from qt4) */,
8EBF3FA503F140960059A3A7 /* vlc.scriptTerminology */,
8EDAC3430440F72D0059A3A7 /* README.MacOSX.rtf */,
......@@ -480,6 +491,8 @@
CC6EDD500B9CA2140096068A /* eyetv.m */,
CCB24D5E0D54BBAE004D780C /* simple_prefs.h */,
CCB24D5D0D54BBAE004D780C /* simple_prefs.m */,
CCB60A3F0E6E5DD900407004 /* vlm.h */,
CCB60A3E0E6E5DD900407004 /* vlm.m */,
);
name = Classes;
sourceTree = "<group>";
......@@ -729,9 +742,20 @@
name = "Native FSPanel icons";
sourceTree = "<group>";
};
CCD90F4A0E87C82D0034564A /* VLM */ = {
isa = PBXGroup;
children = (
CCD90F4B0E87C86D0034564A /* add_schedule.png */,
CCD90F4C0E87C86D0034564A /* add_vod.png */,
CCD90F4D0E87C86D0034564A /* add_broadcast.png */,
);
name = VLM;
sourceTree = "<group>";
};
DCF358BC077F1236007DB450 /* nibs */ = {
isa = PBXGroup;
children = (
CCB60A400E6E5E3F00407004 /* VLM.nib */,
CCC896B80D9AA9E8005AE59C /* MediaInfo.nib */,
DCA00AA7075F948800E6BF46 /* About.nib */,
F74F13EA02C2A79C01EE194C /* MainMenu.nib */,
......@@ -933,6 +957,10 @@
CC402F3D0E00ABBB006A4BA4 /* display_middle.png in Resources */,
CC402F3E0E00ABBB006A4BA4 /* display_left.png in Resources */,
CC402F3F0E00ABBB006A4BA4 /* display_right.png in Resources */,
CCB60A420E6E5E3F00407004 /* VLM.nib in Resources */,
CCD90F4E0E87C86D0034564A /* add_schedule.png in Resources */,
CCD90F4F0E87C86D0034564A /* add_vod.png in Resources */,
CCD90F500E87C86D0034564A /* add_broadcast.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
......@@ -973,6 +1001,14 @@
name = Update.nib;
sourceTree = "<group>";
};
CCB60A400E6E5E3F00407004 /* VLM.nib */ = {
isa = PBXVariantGroup;
children = (
CCB60A410E6E5E3F00407004 /* English */,
);
name = VLM.nib;
sourceTree = "<group>";
};
CCC896B80D9AA9E8005AE59C /* MediaInfo.nib */ = {
isa = PBXVariantGroup;
children = (
......
......@@ -52,5 +52,7 @@ SOURCES_macosx = \
fspanel.h \
eyetv.h \
eyetv.m \
vlm.h \
vlm.m \
$(NULL)
......@@ -102,6 +102,7 @@ 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_interaction_list; /* VLCInteractionList*/
VLCInformation * o_info; /* VLCInformation */
......@@ -118,6 +119,7 @@ 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 */
IBOutlet VLControllerWindow * o_window; /* main window */
IBOutlet NSView * o_playlist_view;/* playlist view */
......@@ -189,6 +191,7 @@ 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;
......@@ -380,6 +383,7 @@ struct intf_sys_t
- (IBAction)intfOpenCapture:(id)sender;
- (IBAction)showWizard:(id)sender;
- (IBAction)showVLM:(id)sender;
- (IBAction)showExtended:(id)sender;
- (IBAction)showBookmarks:(id)sender;
......
......@@ -55,6 +55,7 @@
#import "AppleRemote.h"
#import "eyetv.h"
#import "simple_prefs.h"
#import "vlm.h"
#import <vlc_input.h>
#import <vlc_interface.h>
......@@ -248,6 +249,7 @@ 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];
......@@ -1291,6 +1293,11 @@ static unsigned int VLCModifiersToCocoa( unsigned int i_key )
return nil;
}
- (id)getVLM
{
return o_vlm;
}
- (id)getBookmarks
{
if( o_bookmarks )
......@@ -1985,6 +1992,14 @@ end:
}
}
- (IBAction)showVLM:(id)sender
{
if( !nib_vlm_loaded )
nib_vlm_loaded = [NSBundle loadNibNamed:@"VLM" owner:self];
[o_vlm showVLMWindow];
}
- (IBAction)showExtended:(id)sender
{
if( o_extended == nil )
......
/*****************************************************************************
* vlm.h: VLM Configuration panel for Mac OS X
*****************************************************************************
* Copyright (c) 2008 the VideoLAN team
* $Id$
*
* Authors: Felix Paul Kühne <fkuehne@videolan.org>
*
* 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 <Cocoa/Cocoa.h>
#import "intf.h"
#import <vlc_vlm.h>
@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
/*****************************************************************************
* vlm.m: VLM Configuration panel for Mac OS X
*****************************************************************************
* Copyright (c) 2008 the VideoLAN team
* $Id$
*
* Authors: Felix Paul Kühne <fkuehne@videolan.org>
*
* 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_sprefs_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
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