]> git.sesse.net Git - vlc/blob - modules/gui/macosx/fspanel.h
macosx/CAS: add MKV to the black list for HTTP streaming
[vlc] / modules / gui / macosx / fspanel.h
1 /*****************************************************************************
2  * fspanel.h: MacOS X full screen panel
3  *****************************************************************************
4  * Copyright (C) 2006-2012 VLC authors and VideoLAN
5  * $Id$
6  *
7  * Authors: Jérôme Decoodt <djc at videolan dot org>
8  *          Felix Paul Kühne <fkuehne at videolan dot org>
9  *
10  * This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
23  *****************************************************************************/
24
25 @class VLCWindow;
26
27 @interface VLCFSPanel : NSWindow
28 {
29     NSTimer *fadeTimer,*hideAgainTimer;
30     NSPoint mouseClic;
31     BOOL b_fadeQueued;
32     BOOL b_keptVisible;
33     BOOL b_alreadyCounting;
34     int i_timeToKeepVisibleInSec;
35
36     BOOL b_nonActive;
37     BOOL b_displayed;
38     BOOL b_voutWasUpdated;
39     int i_device;
40
41     VLCWindow *o_vout_window;
42 }
43 - (id)initWithContentRect: (NSRect)contentRect
44                 styleMask: (NSUInteger)aStyle
45                   backing: (NSBackingStoreType)bufferingType
46                     defer: (BOOL)flag;
47 - (void)awakeFromNib;
48 - (BOOL)canBecomeKeyWindow;
49 - (void)dealloc;
50
51 - (void)setPlay;
52 - (void)setPause;
53 - (void)setStreamTitle: (NSString *)o_title;
54 - (void)setStreamPos: (float)f_pos andTime: (NSString *)o_time;
55 - (void)setSeekable: (BOOL)b_seekable;
56 - (void)setVolumeLevel: (int)i_volumeLevel;
57
58 - (void)setNonActive: (id)noData;
59 - (void)setActive: (id)noData;
60
61 - (void)focus: (NSTimer *)timer;
62 - (void)unfocus: (NSTimer *)timer;
63 - (void)mouseExited: (NSEvent *)theEvent;
64
65 - (void)fadeIn;
66 - (void)fadeOut;
67
68 - (NSTimer *)fadeTimer;
69 - (void)setFadeTimer: (NSTimer *)timer;
70 - (void)autoHide;
71 - (void)keepVisible: (NSTimer *)timer;
72
73 - (void)mouseDown: (NSEvent *)theEvent;
74 - (void)mouseDragged: (NSEvent *)theEvent;
75
76 - (void)setVoutWasUpdated: (VLCWindow *)o_window;
77 @end
78
79 @interface VLCFSPanelView : NSView
80 {
81     NSColor *fillColor;
82     NSButton *o_prev, *o_next, *o_bwd, *o_fwd, *o_play, *o_fullscreen;
83     NSTextField *o_streamTitle_txt, *o_streamPosition_txt;
84     NSSlider *o_fs_timeSlider, *o_fs_volumeSlider;
85     NSImage *o_background_img, *o_vol_sld_img, *o_vol_mute_img, *o_vol_max_img, *o_time_sld_img;
86     NSTimeInterval last_fwd_event;
87     NSTimeInterval last_bwd_event;
88 }
89 - (id)initWithFrame: (NSRect)frameRect;
90 - (void)drawRect: (NSRect)rect;
91
92 - (void)setPlay;
93 - (void)setPause;
94 - (void)setStreamTitle: (NSString *)o_title;
95 - (void)setStreamPos: (float)f_pos andTime: (NSString *)o_time;
96 - (void)setSeekable: (BOOL)b_seekable;
97 - (void)setVolumeLevel: (int)i_volumeLevel;
98 - (IBAction)play:(id)sender;
99 - (IBAction)prev:(id)sender;
100 - (IBAction)next:(id)sender;
101 - (IBAction)forward:(id)sender;
102 - (IBAction)backward:(id)sender;
103 - (IBAction)fsTimeSliderUpdate: (id)sender;
104 - (IBAction)fsVolumeSliderUpdate: (id)sender;
105
106 @end
107
108 @interface VLCFSTimeSlider : NSSlider
109 {
110 }
111 - (void)drawKnobInRect: (NSRect)knobRect;
112 - (void)drawRect: (NSRect)rect;
113
114 @end
115
116 @interface VLCFSVolumeSlider : VLCVolumeSliderCommon
117 {
118 }
119 - (void)drawKnobInRect: (NSRect)knobRect;
120 - (void)drawRect: (NSRect)rect;
121
122 @end