Commit f4504578 authored by Felix Paul Kühne's avatar Felix Paul Kühne

macosx: refactor main class object life management and main menu

parent db62975c
......@@ -374,8 +374,6 @@
1CCB5F5B1A62A724004C3E90 /* bookmarks.h in Sources */ = {isa = PBXBuildFile; fileRef = DCE7BD0708A5724D007B10AE /* bookmarks.h */; };
1CCB5F5C1A62A724004C3E90 /* bookmarks.m in Sources */ = {isa = PBXBuildFile; fileRef = DCE7BD0608A5724D007B10AE /* bookmarks.m */; };
1CCB5F5D1A62A724004C3E90 /* CompatibilityFixes.h in Sources */ = {isa = PBXBuildFile; fileRef = CCB0BB3013FAC9F40095BD0A /* CompatibilityFixes.h */; };
1CCB5F5E1A62A724004C3E90 /* controls.h in Sources */ = {isa = PBXBuildFile; fileRef = 8E6BC6FA041684EC0059A3A7 /* controls.h */; };
1CCB5F5F1A62A724004C3E90 /* controls.m in Sources */ = {isa = PBXBuildFile; fileRef = 8ED6C27B03E2EB1C0059A3A7 /* controls.m */; };
1CCB5F601A62A724004C3E90 /* ControlsBar.h in Sources */ = {isa = PBXBuildFile; fileRef = E0382C00160BA09E0031D7FF /* ControlsBar.h */; };
1CCB5F611A62A724004C3E90 /* ControlsBar.m in Sources */ = {isa = PBXBuildFile; fileRef = E0382C01160BA09E0031D7FF /* ControlsBar.m */; };
1CCB5F621A62A724004C3E90 /* ConvertAndSave.h in Sources */ = {isa = PBXBuildFile; fileRef = CC0663341566C34C003A411C /* ConvertAndSave.h */; };
......@@ -1272,12 +1270,10 @@
8E55FB800459B0FD00FB3317 /* output.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = output.m; path = ../../../modules/gui/macosx/output.m; sourceTree = SOURCE_ROOT; };
8E6BC6F6041643860059A3A7 /* applescript.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = applescript.h; path = ../../../modules/gui/macosx/applescript.h; sourceTree = SOURCE_ROOT; };
8E6BC6F7041643860059A3A7 /* applescript.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = applescript.m; path = ../../../modules/gui/macosx/applescript.m; sourceTree = SOURCE_ROOT; };
8E6BC6FA041684EC0059A3A7 /* controls.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = controls.h; path = ../../../modules/gui/macosx/controls.h; sourceTree = SOURCE_ROOT; };
8E9CA1A306D7DEE800B7186C /* prefs_widgets.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = prefs_widgets.h; path = ../../../modules/gui/macosx/prefs_widgets.h; sourceTree = SOURCE_ROOT; };
8E9CA1A406D7DEE800B7186C /* prefs_widgets.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = prefs_widgets.m; path = ../../../modules/gui/macosx/prefs_widgets.m; sourceTree = SOURCE_ROOT; };
8EBF3FA303F13FFB0059A3A7 /* vlc.scriptSuite */ = {isa = PBXFileReference; lastKnownFileType = text; name = vlc.scriptSuite; path = Resources/vlc.scriptSuite; sourceTree = SOURCE_ROOT; };
8EBF3FA503F140960059A3A7 /* vlc.scriptTerminology */ = {isa = PBXFileReference; lastKnownFileType = text.xml; name = vlc.scriptTerminology; path = Resources/vlc.scriptTerminology; sourceTree = SOURCE_ROOT; };
8ED6C27B03E2EB1C0059A3A7 /* controls.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = controls.m; path = ../../../modules/gui/macosx/controls.m; sourceTree = SOURCE_ROOT; };
8ED6C27C03E2EB1C0059A3A7 /* intf.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = intf.h; path = ../../../modules/gui/macosx/intf.h; sourceTree = SOURCE_ROOT; };
8ED6C27D03E2EB1C0059A3A7 /* intf.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = intf.m; path = ../../../modules/gui/macosx/intf.m; sourceTree = SOURCE_ROOT; };
8ED6C27E03E2EB1C0059A3A7 /* macosx.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = macosx.m; path = ../../../modules/gui/macosx/macosx.m; sourceTree = SOURCE_ROOT; };
......@@ -1827,8 +1823,6 @@
DCE7BD0708A5724D007B10AE /* bookmarks.h */,
DCE7BD0608A5724D007B10AE /* bookmarks.m */,
CCB0BB3013FAC9F40095BD0A /* CompatibilityFixes.h */,
8E6BC6FA041684EC0059A3A7 /* controls.h */,
8ED6C27B03E2EB1C0059A3A7 /* controls.m */,
E0382C00160BA09E0031D7FF /* ControlsBar.h */,
E0382C01160BA09E0031D7FF /* ControlsBar.m */,
CC0663341566C34C003A411C /* ConvertAndSave.h */,
......@@ -3854,8 +3848,6 @@
1CCB5F5B1A62A724004C3E90 /* bookmarks.h in Sources */,
1CCB5F5C1A62A724004C3E90 /* bookmarks.m in Sources */,
1CCB5F5D1A62A724004C3E90 /* CompatibilityFixes.h in Sources */,
1CCB5F5E1A62A724004C3E90 /* controls.h in Sources */,
1CCB5F5F1A62A724004C3E90 /* controls.m in Sources */,
1CCB5F601A62A724004C3E90 /* ControlsBar.h in Sources */,
1CCB5F611A62A724004C3E90 /* ControlsBar.m in Sources */,
1CCB5F621A62A724004C3E90 /* ConvertAndSave.h in Sources */,
......
......@@ -1104,7 +1104,7 @@ else \
- (IBAction)effects:(id)sender
{
[[VLCMainMenu sharedInstance] showAudioEffects: sender];
[[[VLCMain sharedInstance] mainMenu] showAudioEffects: sender];
}
#pragma mark -
......@@ -1161,7 +1161,7 @@ else \
[o_next_btn setEnabled: (b_seekable || b_plmul || b_chapters)];
}
[[VLCMainMenu sharedInstance] setRateControlsEnabled: b_control];
[[[VLCMain sharedInstance] mainMenu] setRateControlsEnabled: b_control];
}
@end
......@@ -66,6 +66,7 @@
- (void)volumeUp;
- (void)volumeDown;
- (void)toggleMute;
- (void)showPosition;
- (void)startListeningWithAppleRemote;
- (void)stopListeningWithAppleRemote;
......@@ -82,6 +83,7 @@
- (void)setVideoFilterProperty: (const char *)psz_name forFilter: (const char *)psz_filter string: (const char *)psz_value;
- (void)setVideoFilterProperty: (const char *)psz_name forFilter: (const char *)psz_filter boolean: (BOOL)b_value;
- (BOOL)keyEvent:(NSEvent *)o_event;
- (void)updateCurrentlyUsedHotkeys;
- (BOOL)hasDefinedShortcutKey:(NSEvent *)o_event force:(BOOL)b_force;
......
......@@ -40,7 +40,6 @@
#import "SPMediaKeyTap.h"
#import "AppleRemote.h"
#import "InputManager.h"
#import "controls.h"
static int BossCallback(vlc_object_t *p_this, const char *psz_var,
vlc_value_t oldval, vlc_value_t new_val, void *param)
......@@ -616,6 +615,19 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var,
vlc_object_release(p_input);
}
- (void)showPosition
{
input_thread_t *p_input = pl_CurrentInput(VLCIntf);
if (p_input != NULL) {
vout_thread_t *p_vout = input_GetVout(p_input);
if (p_vout != NULL) {
var_SetInteger(VLCIntf->p_libvlc, "key-action", ACTIONID_POSITION);
vlc_object_release(p_vout);
}
vlc_object_release(p_input);
}
}
#pragma mark - drag and drop support for VLCVoutView, VLCDragDropView and VLCThreePartDropView
- (BOOL)performDragOperation:(id <NSDraggingInfo>)sender
{
......@@ -1152,7 +1164,7 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var,
}
break;
case kRemoteButtonMenu:
[[[VLCMain sharedInstance] controls] showPosition: self]; //FIXME
[self showPosition];
break;
case kRemoteButtonPlay_Sleep:
{
......@@ -1174,6 +1186,36 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var,
* shortcut key. If it is, pass it off to VLC for handling and return YES,
* otherwise ignore it and return NO (where it will get handled by Cocoa).
*****************************************************************************/
- (BOOL)keyEvent:(NSEvent *)o_event
{
BOOL eventHandled = NO;
NSString * characters = [o_event charactersIgnoringModifiers];
if ([characters length] > 0) {
unichar key = [characters characterAtIndex: 0];
if (key) {
input_thread_t * p_input = pl_CurrentInput(VLCIntf);
if (p_input != NULL) {
vout_thread_t *p_vout = input_GetVout(p_input);
if (p_vout != NULL) {
/* Escape */
if (key == (unichar) 0x1b) {
if (var_GetBool(p_vout, "fullscreen")) {
[self toggleFullscreen];
eventHandled = YES;
}
}
vlc_object_release(p_vout);
}
vlc_object_release(p_input);
}
}
}
return eventHandled;
}
- (BOOL)hasDefinedShortcutKey:(NSEvent *)o_event force:(BOOL)b_force
{
intf_thread_t *p_intf = VLCIntf;
......
/*****************************************************************************
* MainMenu.h: MacOS X interface module
*MainMenu.h: MacOS X interface module
*****************************************************************************
* Copyright (C) 2011-2014 Felix Paul Kühne
* $Id$
*Copyright (C) 2011-2015 Felix Paul Kühne
*$Id$
*
* Authors: Felix Paul Kühne <fkuehne -at- videolan -dot- org>
*Authors: Felix Paul Kühne <fkuehne -at- videolan -dot- 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 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.
*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., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*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., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#import <Cocoa/Cocoa.h>
#import <vlc_common.h>
#import <vlc_interface.h>
@class AboutWindowController;
@class AddonsWindowController;
@class HelpWindowController;
@interface VLCMainMenu : NSObject
{
/* main menu */
IBOutlet NSMenuItem * o_mi_about;
IBOutlet NSMenuItem * o_mi_prefs;
IBOutlet NSMenuItem * o_mi_checkForUpdate;
IBOutlet NSMenuItem * o_mi_extensions;
IBOutlet NSMenu * o_mu_extensions;
IBOutlet NSMenuItem * o_mi_addonManager;
IBOutlet NSMenuItem * o_mi_add_intf;
IBOutlet NSMenu * o_mu_add_intf;
IBOutlet NSMenuItem * o_mi_services;
IBOutlet NSMenuItem * o_mi_hide;
IBOutlet NSMenuItem * o_mi_hide_others;
IBOutlet NSMenuItem * o_mi_show_all;
IBOutlet NSMenuItem * o_mi_quit;
IBOutlet NSMenu * o_mu_file;
IBOutlet NSMenuItem * o_mi_open_file;
IBOutlet NSMenuItem * o_mi_open_generic;
IBOutlet NSMenuItem * o_mi_open_disc;
IBOutlet NSMenuItem * o_mi_open_net;
IBOutlet NSMenuItem * o_mi_open_capture;
IBOutlet NSMenuItem * o_mi_open_recent;
IBOutlet NSMenuItem * o_mi_close_window;
IBOutlet NSMenuItem * o_mi_convertandsave;
IBOutlet NSMenuItem * o_mi_save_playlist;
IBOutlet NSMenuItem * o_mi_revealInFinder;
IBOutlet NSMenu * o_mu_edit;
IBOutlet NSMenuItem * o_mi_cut;
IBOutlet NSMenuItem * o_mi_copy;
IBOutlet NSMenuItem * o_mi_paste;
IBOutlet NSMenuItem * o_mi_clear;
IBOutlet NSMenuItem * o_mi_select_all;
IBOutlet NSMenu * o_mu_view;
IBOutlet NSMenuItem * o_mi_toggleJumpButtons;
IBOutlet NSMenuItem * o_mi_togglePlaymodeButtons;
IBOutlet NSMenuItem * o_mi_toggleEffectsButton;
IBOutlet NSMenuItem * o_mi_toggleSidebar;
IBOutlet NSMenu * o_mu_playlistTableColumns;
IBOutlet NSMenuItem * o_mi_playlistTableColumns;
NSMenu * o_mu_playlistTableColumnsContextMenu;
IBOutlet NSMenu * o_mu_controls;
IBOutlet NSMenuItem * o_mi_play;
IBOutlet NSMenuItem * o_mi_stop;
IBOutlet NSMenuItem * o_mi_record;
IBOutlet NSMenuItem * o_mi_rate;
IBOutlet NSView * o_mi_rate_view;
IBOutlet id o_mi_rate_lbl;
IBOutlet id o_mi_rate_slower_lbl;
IBOutlet id o_mi_rate_normal_lbl;
IBOutlet id o_mi_rate_faster_lbl;
IBOutlet id o_mi_rate_sld;
IBOutlet id o_mi_rate_fld;
IBOutlet NSMenuItem * o_mi_trackSynchronization;
IBOutlet NSMenuItem * o_mi_previous;
IBOutlet NSMenuItem * o_mi_next;
IBOutlet NSMenuItem * o_mi_random;
IBOutlet NSMenuItem * o_mi_repeat;
IBOutlet NSMenuItem * o_mi_loop;
IBOutlet NSMenuItem * o_mi_AtoBloop;
IBOutlet NSMenuItem * o_mi_quitAfterPB;
IBOutlet NSMenuItem * o_mi_fwd;
IBOutlet NSMenuItem * o_mi_bwd;
IBOutlet NSMenuItem * o_mi_program;
IBOutlet NSMenu * o_mu_program;
IBOutlet NSMenuItem * o_mi_title;
IBOutlet NSMenu * o_mu_title;
IBOutlet NSMenuItem * o_mi_chapter;
IBOutlet NSMenu * o_mu_chapter;
IBOutlet NSMenu * o_mu_audio;
IBOutlet NSMenuItem * o_mi_vol_up;
IBOutlet NSMenuItem * o_mi_vol_down;
IBOutlet NSMenuItem * o_mi_mute;
IBOutlet NSMenuItem * o_mi_audiotrack;
IBOutlet NSMenu * o_mu_audiotrack;
IBOutlet NSMenuItem * o_mi_channels;
IBOutlet NSMenu * o_mu_channels;
IBOutlet NSMenuItem * o_mi_device;
IBOutlet NSMenu * o_mu_device;
IBOutlet NSMenuItem * o_mi_visual;
IBOutlet NSMenu * o_mu_visual;
IBOutlet NSMenu * o_mu_video;
IBOutlet NSMenuItem * o_mi_half_window;
IBOutlet NSMenuItem * o_mi_normal_window;
IBOutlet NSMenuItem * o_mi_double_window;
IBOutlet NSMenuItem * o_mi_fittoscreen;
IBOutlet NSMenuItem * o_mi_fullscreen;
IBOutlet NSMenuItem * o_mi_floatontop;
IBOutlet NSMenuItem * o_mi_snapshot;
IBOutlet NSMenuItem * o_mi_videotrack;
IBOutlet NSMenu * o_mu_videotrack;
IBOutlet NSMenuItem * o_mi_screen;
IBOutlet NSMenu * o_mu_screen;
IBOutlet NSMenuItem * o_mi_aspect_ratio;
IBOutlet NSMenu * o_mu_aspect_ratio;
IBOutlet NSMenuItem * o_mi_crop;
IBOutlet NSMenu * o_mu_crop;
IBOutlet NSMenuItem * o_mi_deinterlace;
IBOutlet NSMenu * o_mu_deinterlace;
IBOutlet NSMenuItem * o_mi_deinterlace_mode;
IBOutlet NSMenu * o_mu_deinterlace_mode;
IBOutlet NSMenuItem * o_mi_ffmpeg_pp;
IBOutlet NSMenu * o_mu_ffmpeg_pp;
IBOutlet NSMenu * o_mu_subtitles;
IBOutlet NSMenuItem * o_mi_subtitle_track;
IBOutlet NSMenu * o_mu_subtitle_tracks;
IBOutlet NSMenuItem * o_mi_openSubtitleFile;
IBOutlet NSMenu * o_mu_subtitle_size;
IBOutlet NSMenuItem *o_mi_subtitle_size;
IBOutlet NSMenu * o_mu_subtitle_textcolor;
IBOutlet NSMenuItem *o_mi_subtitle_textcolor;
IBOutlet NSMenu * o_mu_subtitle_bgcolor;
IBOutlet NSMenuItem * o_mi_subtitle_bgcolor;
IBOutlet NSMenuItem * o_mi_subtitle_bgopacity;
IBOutlet NSView * o_mi_subtitle_bgopacity_view;
IBOutlet id o_mi_subtitle_bgopacity_lbl;
IBOutlet id o_mi_subtitle_bgopacity_lbl_gray;
IBOutlet id o_mi_subtitle_bgopacity_sld;
IBOutlet NSMenu * o_mu_subtitle_outlinethickness;
IBOutlet NSMenuItem * o_mi_subtitle_outlinethickness;
IBOutlet NSMenuItem * o_mi_teletext;
IBOutlet NSMenuItem * o_mi_teletext_transparent;
IBOutlet NSMenuItem * o_mi_teletext_index;
IBOutlet NSMenuItem * o_mi_teletext_red;
IBOutlet NSMenuItem * o_mi_teletext_green;
IBOutlet NSMenuItem * o_mi_teletext_yellow;
IBOutlet NSMenuItem * o_mi_teletext_blue;
IBOutlet NSMenu * o_mu_window;
IBOutlet NSMenuItem * o_mi_minimize;
IBOutlet NSMenuItem * o_mi_zoom_window;
IBOutlet NSMenuItem * o_mi_player;
IBOutlet NSMenuItem * o_mi_controller;
IBOutlet NSMenuItem * o_mi_audioeffects;
IBOutlet NSMenuItem * o_mi_videoeffects;
IBOutlet NSMenuItem * o_mi_bookmarks;
IBOutlet NSMenuItem * o_mi_playlist;
IBOutlet NSMenuItem * o_mi_info;
IBOutlet NSMenuItem * o_mi_messages;
IBOutlet NSMenuItem * o_mi_bring_atf;
IBOutlet NSMenu * o_mu_help;
IBOutlet NSMenuItem * o_mi_help;
IBOutlet NSMenuItem * o_mi_readme;
IBOutlet NSMenuItem * o_mi_documentation;
IBOutlet NSMenuItem * o_mi_license;
IBOutlet NSMenuItem * o_mi_website;
IBOutlet NSMenuItem * o_mi_donation;
IBOutlet NSMenuItem * o_mi_forum;
IBOutlet NSMenuItem * o_mi_errorsAndWarnings;
/* dock menu */
IBOutlet NSMenuItem * o_dmi_play;
IBOutlet NSMenuItem * o_dmi_stop;
IBOutlet NSMenuItem * o_dmi_next;
IBOutlet NSMenuItem * o_dmi_previous;
IBOutlet NSMenuItem * o_dmi_mute;
/* vout menu */
IBOutlet NSMenu * o_vout_menu;
IBOutlet NSMenuItem * o_vmi_play;
IBOutlet NSMenuItem * o_vmi_stop;
IBOutlet NSMenuItem * o_vmi_prev;
IBOutlet NSMenuItem * o_vmi_next;
IBOutlet NSMenuItem * o_vmi_volup;
IBOutlet NSMenuItem * o_vmi_voldown;
IBOutlet NSMenuItem * o_vmi_mute;
IBOutlet NSMenuItem * o_vmi_fullscreen;
IBOutlet NSMenuItem * o_vmi_snapshot;
}
+ (VLCMainMenu *)sharedInstance;
- (void)initStrings;
/* main menu */
@property (readwrite, weak) IBOutlet NSMenuItem *about;
@property (readwrite, weak) IBOutlet NSMenuItem *prefs;
@property (readwrite, weak) IBOutlet NSMenuItem *checkForUpdate;
@property (readwrite, weak) IBOutlet NSMenuItem *extensions;
@property (readwrite, weak) IBOutlet NSMenu *extensionsMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *addonManager;
@property (readwrite, weak) IBOutlet NSMenuItem *add_intf;
@property (readwrite, weak) IBOutlet NSMenu *add_intfMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *services;
@property (readwrite, weak) IBOutlet NSMenuItem *hide;
@property (readwrite, weak) IBOutlet NSMenuItem *hide_others;
@property (readwrite, weak) IBOutlet NSMenuItem *show_all;
@property (readwrite, weak) IBOutlet NSMenuItem *quit;
@property (readwrite, weak) IBOutlet NSMenu *fileMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *open_file;
@property (readwrite, weak) IBOutlet NSMenuItem *open_generic;
@property (readwrite, weak) IBOutlet NSMenuItem *open_disc;
@property (readwrite, weak) IBOutlet NSMenuItem *open_net;
@property (readwrite, weak) IBOutlet NSMenuItem *open_capture;
@property (readwrite, weak) IBOutlet NSMenuItem *open_recent;
@property (readwrite, weak) IBOutlet NSMenuItem *close_window;
@property (readwrite, weak) IBOutlet NSMenuItem *convertandsave;
@property (readwrite, weak) IBOutlet NSMenuItem *save_playlist;
@property (readwrite, weak) IBOutlet NSMenuItem *revealInFinder;
@property (readwrite, weak) IBOutlet NSMenu *editMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *cutItem;
@property (readwrite, weak) IBOutlet NSMenuItem *mcopyItem;
@property (readwrite, weak) IBOutlet NSMenuItem *pasteItem;
@property (readwrite, weak) IBOutlet NSMenuItem *clearItem;
@property (readwrite, weak) IBOutlet NSMenuItem *select_all;
@property (readwrite, weak) IBOutlet NSMenu *viewMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *toggleJumpButtons;
@property (readwrite, weak) IBOutlet NSMenuItem *togglePlaymodeButtons;
@property (readwrite, weak) IBOutlet NSMenuItem *toggleEffectsButton;
@property (readwrite, weak) IBOutlet NSMenuItem *toggleSidebar;
@property (readwrite, weak) IBOutlet NSMenu *playlistTableColumnsMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *playlistTableColumns;
@property (readwrite, weak) IBOutlet NSMenu *controlsMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *play;
@property (readwrite, weak) IBOutlet NSMenuItem *stop;
@property (readwrite, weak) IBOutlet NSMenuItem *record;
@property (readwrite, weak) IBOutlet NSMenuItem *rate;
@property (readwrite, weak) IBOutlet NSView *rate_view;
@property (readwrite, weak) IBOutlet NSTextField *rateLabel;
@property (readwrite, weak) IBOutlet NSTextField *rate_slowerLabel;
@property (readwrite, weak) IBOutlet NSTextField *rate_normalLabel;
@property (readwrite, weak) IBOutlet NSTextField *rate_fasterLabel;
@property (readwrite, weak) IBOutlet NSSlider *rate_sld;
@property (readwrite, weak) IBOutlet NSTextField *rateTextField;
@property (readwrite, weak) IBOutlet NSMenuItem *trackSynchronization;
@property (readwrite, weak) IBOutlet NSMenuItem *previous;
@property (readwrite, weak) IBOutlet NSMenuItem *next;
@property (readwrite, weak) IBOutlet NSMenuItem *random;
@property (readwrite, weak) IBOutlet NSMenuItem *repeat;
@property (readwrite, weak) IBOutlet NSMenuItem *loop;
@property (readwrite, weak) IBOutlet NSMenuItem *AtoBloop;
@property (readwrite, weak) IBOutlet NSMenuItem *quitAfterPB;
@property (readwrite, weak) IBOutlet NSMenuItem *fwd;
@property (readwrite, weak) IBOutlet NSMenuItem *bwd;
@property (readwrite, weak) IBOutlet NSMenuItem *jumpToTime;
@property (readwrite, weak) IBOutlet NSMenuItem *program;
@property (readwrite, weak) IBOutlet NSMenu *programMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *title;
@property (readwrite, weak) IBOutlet NSMenu *titleMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *chapter;
@property (readwrite, weak) IBOutlet NSMenu *chapterMenu;
@property (readwrite, weak) IBOutlet NSMenu *audioMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *vol_up;
@property (readwrite, weak) IBOutlet NSMenuItem *vol_down;
@property (readwrite, weak) IBOutlet NSMenuItem *mute;
@property (readwrite, weak) IBOutlet NSMenuItem *audiotrack;
@property (readwrite, weak) IBOutlet NSMenu *audiotrackMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *channels;
@property (readwrite, weak) IBOutlet NSMenu *channelsMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *audioDevice;
@property (readwrite, weak) IBOutlet NSMenu *audioDeviceMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *visual;
@property (readwrite, weak) IBOutlet NSMenu *visualMenu;
@property (readwrite, weak) IBOutlet NSMenu *videoMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *half_window;
@property (readwrite, weak) IBOutlet NSMenuItem *normal_window;
@property (readwrite, weak) IBOutlet NSMenuItem *double_window;
@property (readwrite, weak) IBOutlet NSMenuItem *fittoscreen;
@property (readwrite, weak) IBOutlet NSMenuItem *fullscreenItem;
@property (readwrite, weak) IBOutlet NSMenuItem *floatontop;
@property (readwrite, weak) IBOutlet NSMenuItem *snapshot;
@property (readwrite, weak) IBOutlet NSMenuItem *videotrack;
@property (readwrite, weak) IBOutlet NSMenu *videotrackMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *screen;
@property (readwrite, weak) IBOutlet NSMenu *screenMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *aspect_ratio;
@property (readwrite, weak) IBOutlet NSMenu *aspect_ratioMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *crop;
@property (readwrite, weak) IBOutlet NSMenu *cropMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *deinterlace;
@property (readwrite, weak) IBOutlet NSMenu *deinterlaceMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *deinterlace_mode;
@property (readwrite, weak) IBOutlet NSMenu *deinterlace_modeMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *postprocessing;
@property (readwrite, weak) IBOutlet NSMenu *postprocessingMenu;
@property (readwrite, weak) IBOutlet NSMenu *subtitlesMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_track;
@property (readwrite, weak) IBOutlet NSMenu *subtitle_tracksMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *openSubtitleFile;
@property (readwrite, weak) IBOutlet NSMenu *subtitle_sizeMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_size;
@property (readwrite, weak) IBOutlet NSMenu *subtitle_textcolorMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_textcolor;
@property (readwrite, weak) IBOutlet NSMenu *subtitle_bgcolorMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_bgcolor;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_bgopacity;
@property (readwrite, weak) IBOutlet NSView *subtitle_bgopacity_view;
@property (readwrite, weak) IBOutlet NSTextField *subtitle_bgopacityLabel;
@property (readwrite, weak) IBOutlet NSTextField *subtitle_bgopacityLabel_gray;
@property (readwrite, weak) IBOutlet NSSlider *subtitle_bgopacity_sld;
@property (readwrite, weak) IBOutlet NSMenu *subtitle_outlinethicknessMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *subtitle_outlinethickness;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_transparent;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_index;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_red;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_green;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_yellow;
@property (readwrite, weak) IBOutlet NSMenuItem *teletext_blue;
@property (readwrite, weak) IBOutlet NSMenu *windowMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *minimize;
@property (readwrite, weak) IBOutlet NSMenuItem *zoom_window;
@property (readwrite, weak) IBOutlet NSMenuItem *player;
@property (readwrite, weak) IBOutlet NSMenuItem *controller;
@property (readwrite, weak) IBOutlet NSMenuItem *audioeffects;
@property (readwrite, weak) IBOutlet NSMenuItem *videoeffects;
@property (readwrite, weak) IBOutlet NSMenuItem *bookmarks;
@property (readwrite, weak) IBOutlet NSMenuItem *playlist;
@property (readwrite, weak) IBOutlet NSMenuItem *info;
@property (readwrite, weak) IBOutlet NSMenuItem *messages;
@property (readwrite, weak) IBOutlet NSMenuItem *bring_atf;
@property (readwrite, weak) IBOutlet NSMenu *helpMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *help;
@property (readwrite, weak) IBOutlet NSMenuItem *readme;
@property (readwrite, weak) IBOutlet NSMenuItem *documentation;
@property (readwrite, weak) IBOutlet NSMenuItem *license;
@property (readwrite, weak) IBOutlet NSMenuItem *website;
@property (readwrite, weak) IBOutlet NSMenuItem *donation;
@property (readwrite, weak) IBOutlet NSMenuItem *forum;
@property (readwrite, weak) IBOutlet NSMenuItem *errorsAndWarnings;
/* dock menu */
@property (readwrite, weak) IBOutlet NSMenuItem *dockMenuplay;
@property (readwrite, weak) IBOutlet NSMenuItem *dockMenustop;
@property (readwrite, weak) IBOutlet NSMenuItem *dockMenunext;
@property (readwrite, weak) IBOutlet NSMenuItem *dockMenuprevious;
@property (readwrite, weak) IBOutlet NSMenuItem *dockMenumute;
/* vout menu */
@property (readwrite, weak) IBOutlet NSMenu *voutMenu;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenuplay;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenustop;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenuprev;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenunext;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenuvolup;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenuvoldown;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenumute;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenufullscreen;
@property (readwrite, weak) IBOutlet NSMenuItem *voutMenusnapshot;
@property (readwrite, weak) IBOutlet NSButton *specificTime_cancelButton;
@property (readwrite, weak) IBOutlet NSTextField *specificTime_enterTextField;
@property (readwrite, weak) IBOutlet NSTextField *specificTime_goToLabel;
@property (readwrite, weak) IBOutlet NSButton *specificTime_okButton;
@property (readwrite, weak) IBOutlet NSWindow *specificTimeWindow;
@property (readwrite, weak) IBOutlet NSTextField *specificTime_secLabel;
@property (readwrite, weak) IBOutlet NSStepper *specificTime_stepper;
@property (nonatomic) int jumpTimeValue;
- (void)releaseRepresentedObjects:(NSMenu *)the_menu;
- (void)setupMenus;
- (void)refreshVoutDeviceMenu:(NSNotification *)o_notification;
- (void)setSubmenusEnabled:(BOOL)b_enabled;
- (void)setRateControlsEnabled:(BOOL)b_enabled;
- (void)updateSidebarMenuItem;
......@@ -232,10 +232,27 @@
- (IBAction)toggleJumpButtons:(id)sender;
- (IBAction)togglePlaymodeButtons:(id)sender;
- (IBAction)toggleSidebar:(id)sender;
- (IBAction)togglePlaylistColumnTable:(id)sender;
- (BOOL)setPlaylistColumnTableState:(NSInteger)i_state forColumn:(NSString *)o_column;
- (NSMenu *)setupPlaylistTableColumnsMenu;
- (IBAction)play:(id)sender;
- (IBAction)stop:(id)sender;
- (IBAction)prev:(id)sender;
- (IBAction)next:(id)sender;
- (IBAction)random:(id)sender;
- (IBAction)repeat:(id)sender;
- (IBAction)loop:(id)sender;
- (IBAction)forward:(id)sender;
- (IBAction)backward:(id)sender;
- (IBAction)volumeUp:(id)sender;
- (IBAction)volumeDown:(id)sender;
- (IBAction)mute:(id)sender;
- (IBAction)goToSpecificTime:(id)sender;
- (IBAction)quitAfterPlayback:(id)sender;
- (IBAction)toggleRecord:(id)sender;
- (void)updateRecordState:(BOOL)b_value;
......@@ -243,20 +260,15 @@
- (void)updatePlaybackRate;
- (IBAction)toggleAtoBloop:(id)sender;
- (IBAction)toggleAudioDevice:(id)sender;
- (IBAction)toggleFullscreen:(id)sender;
- (IBAction)resizeVideoWindow:(id)sender;
- (IBAction)floatOnTop:(id)sender;
- (IBAction)createVideoSnapshot:(id)sender;
- (IBAction)toggleFullscreenDevice:(id)sender;
- (IBAction)addSubtitleFile:(id)sender;
- (IBAction)switchSubtitleOption:(id)sender;
- (IBAction)switchSubtitleBackgroundOpacity:(id)sender;
- (IBAction)telxTransparent:(id)sender;
- (IBAction)telxNavLink:(id)sender;
- (IBAction)togglePostProcessing:(id)sender;
- (IBAction)showConvertAndSave:(id)sender;
- (IBAction)showVideoEffects:(id)sender;
......@@ -265,16 +277,16 @@
- (IBAction)showBookmarks:(id)sender;
- (IBAction)showInformationPanel:(id)sender;
- (IBAction)viewAbout:(id)sender;
- (IBAction)showAbout:(id)sender;
- (IBAction)showLicense:(id)sender;
- (IBAction)viewPreferences:(id)sender;
- (IBAction)viewHelp:(id)sender;
- (IBAction)showPreferences:(id)sender;
- (IBAction)showHelp:(id)sender;
- (IBAction)openReadMe:(id)sender;
- (IBAction)openDocumentation:(id)sender;
- (IBAction)openWebsite:(id)sender;
- (IBAction)openForum:(id)sender;
- (IBAction)openDonate:(id)sender;
- (IBAction)viewErrorsAndWarnings:(id)sender;
- (IBAction)showErrorsAndWarnings:(id)sender;
- (IBAction)showMessagesPanel:(id)showMessagesPanel;
- (IBAction)showMainWindow:(id)sender;
- (IBAction)showPlaylist:(id)sender;
......@@ -285,34 +297,14 @@
- (void)setRepeatAll;
- (void)setRepeatOff;
- (void)setShuffle;
- (IBAction)toggleVar:(id)sender;
- (int)toggleVarThread:(id)_o_data;
- (void)setupVarMenuItem:(NSMenuItem *)o_mi
target:(vlc_object_t *)p_object
var:(const char *)psz_variable
selector:(SEL)pf_callback;
- (void)setupVarMenu:(NSMenu *)o_menu
forMenuItem: (NSMenuItem *)o_parent
target:(vlc_object_t *)p_object
var:(const char *)psz_variable
selector:(SEL)pf_callback;
- (id)voutMenu;
@end
/*****************************************************************************
* VLCAutoGeneratedMenuContent interface
*VLCAutoGeneratedMenuContent interface
*****************************************************************************
* This holds our data for autogenerated menus
*This holds our data for autogenerated menus
*****************************************************************************/
@interface VLCAutoGeneratedMenuContent : NSObject
{
char *psz_name;
vlc_object_t * _vlc_object;
vlc_value_t value;
int i_type;
}
- (id)initWithVariableName: (const char *)name
ofObject: (vlc_object_t *)object
......
This diff is collapsed.
......@@ -32,7 +32,6 @@
#import "AudioEffects.h"
#import "MainMenu.h"
#import "open.h"
#import "controls.h" // TODO: remove me