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