/*****************************************************************************
* MainWindow.h: MacOS X interface module
*****************************************************************************
- * Copyright (C) 2002-2012 VLC authors and VideoLAN
+ * Copyright (C) 2002-2014 VLC authors and VideoLAN
* $Id$
*
* Authors: Felix Paul Kühne <fkuehne -at- videolan -dot- org>
* Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr>
* Derk-Jan Hartman <hartman at videolan.org>
+ * David Fuhrmann <david dot fuhrmann at googlemail dot com>
*
* 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
*****************************************************************************/
#import <Cocoa/Cocoa.h>
-#import "CompatibilityFixes.h"
#import "PXSourceList.h"
#import "PXSourceListDataSource.h"
@class VLCMainWindowControlsBar;
@class VLCVoutView;
+typedef enum {
+ psUserEvent,
+ psUserMenuEvent,
+ psVideoStartedOrStoppedEvent,
+ psPlaylistItemChangedEvent
+} VLCPlaylistStateEvent;
+
@interface VLCMainWindow : VLCVideoWindowCommon <PXSourceListDataSource, PXSourceListDelegate, NSWindowDelegate, NSAnimationDelegate, NSSplitViewDelegate> {
IBOutlet id o_search_fld;
-
+
IBOutlet id o_playlist_table;
IBOutlet id o_split_view;
IBOutlet id o_left_split_view;
IBOutlet id o_dropzone_btn;
IBOutlet id o_dropzone_lbl;
IBOutlet id o_dropzone_box;
+ IBOutlet id o_dropzone_img;
- IBOutlet VLCFSPanel *o_fspanel;
+ VLCFSPanel *o_fspanel;
IBOutlet id o_podcast_view;
IBOutlet id o_podcast_add_btn;
BOOL b_splitview_removed;
BOOL b_minimized_view;
- int i_lastSplitViewHeight;
+ CGFloat f_lastSplitViewHeight;
+ CGFloat f_lastLeftSplitViewWidth;
NSMutableArray *o_sidebaritems;
- BOOL b_nonembedded;
- BOOL b_podcastView_displayed;
+ /* this is only true, when we have NO video playing inside the main window */
+ BOOL b_nonembedded;
- VLCWindow * o_fullscreen_window;
- NSViewAnimation * o_fullscreen_anim1;
- NSViewAnimation * o_fullscreen_anim2;
- NSViewAnimation * o_makekey_anim;
- NSView * o_temp_view;
- /* set to yes if we are fullscreen and all animations are over */
- BOOL b_fullscreen;
- BOOL b_window_is_invisible;
- NSRecursiveLock * o_animation_lock;
-
- NSTimer *t_hide_mouse_timer;
+ BOOL b_podcastView_displayed;
VLCColorView * o_color_backdrop;
- NSInteger i_originalLevel;
-
- id o_current_video_window;
NSRect frameBeforePlayback;
}
+ (VLCMainWindow *)sharedInstance;
-@property (readonly) BOOL fullscreen;
+@property (readonly) BOOL nativeFullscreenMode;
+@property (readwrite) BOOL nonembedded;
+
+@property (readonly) VLCFSPanel* fsPanel;
- (VLCMainWindowControlsBar *)controlsBar;
-- (IBAction)togglePlaylist:(id)sender;
+- (void)changePlaylistState:(VLCPlaylistStateEvent)event;
- (IBAction)dropzoneButtonAction:(id)sender;
- (void)windowResizedOrMoved:(NSNotification *)notification;
+- (void)reloadSidebar;
+
+- (void)toggleLeftSubSplitView;
- (void)showDropZone;
- (void)hideDropZone;
-- (void)showSplitView;
-- (void)hideSplitView;
- (void)updateTimeSlider;
- (void)updateWindow;
- (void)updateName;
- (void)setPlay;
- (void)updateVolumeSlider;
-- (VLCVoutView *)setupVout:(vout_window_t *)p_wnd;
-- (void)setVideoplayEnabled;
-
-- (void)hideMouseCursor:(NSTimer *)timer;
-- (void)recreateHideMouseTimer;
-
-/* fullscreen handling */
- (void)showFullscreenController;
-- (void)lockFullscreenAnimation;
-- (void)unlockFullscreenAnimation;
-- (void)enterFullscreen;
-- (void)leaveFullscreen;
-- (void)leaveFullscreenAndFadeOut: (BOOL)fadeout;
-- (void)hasEndedFullscreen;
-- (void)hasBecomeFullscreen;
-
-/* lion's native fullscreen handling */
-- (void)windowWillEnterFullScreen:(NSNotification *)notification;
-- (void)windowDidEnterFullScreen:(NSNotification *)notification;
-- (void)windowWillExitFullScreen:(NSNotification *)notification;
+
+- (void)videoplayWillBeStarted;
+- (void)setVideoplayEnabled;
@end
@interface VLCDetachedVideoWindow : VLCVideoWindowCommon
+{
+ VLCColorView * o_color_backdrop;
+}
-@end
\ No newline at end of file
+@end