]> git.sesse.net Git - vlc/blob - modules/gui/macosx/vout.h
* I should get some sleep now
[vlc] / modules / gui / macosx / vout.h
1 /*****************************************************************************
2  * vout.h: MacOS X interface module
3  *****************************************************************************
4  * Copyright (C) 2001-2006 the VideoLAN team
5  * $Id$
6  *
7  * Authors: Colin Delacroix <colin@zoy.org>
8  *          Florian G. Pflug <fgp@phlo.org>
9  *          Jon Lech Johansen <jon-vl@nanocrew.net>
10  *          Eric Petit <titer@m0k.org>
11  *          Benjamin Pracht <bigben at videolan dot org>
12  *
13  * This program is free software; you can redistribute it and/or modify
14  * it under the terms of the GNU General Public License as published by
15  * the Free Software Foundation; either version 2 of the License, or
16  * (at your option) any later version.
17  * 
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
21  * GNU General Public License for more details.
22  *
23  * You should have received a copy of the GNU General Public License
24  * along with this program; if not, write to the Free Software
25  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
26  *****************************************************************************/
27
28 /*****************************************************************************
29  * VLCEmbeddedList interface
30  *****************************************************************************/
31 @interface VLCEmbeddedList : NSObject
32 {
33     NSMutableArray * o_embedded_array;
34 }
35
36 - (id)getEmbeddedVout;
37 - (void)releaseEmbeddedVout: (id)o_vout_view;
38 - (void)addEmbeddedVout: (id)o_vout_view;
39 - (BOOL)windowContainsEmbedded: (id)o_window;
40 - (id)getViewForWindow: (id)o_window;
41
42 @end
43
44 /*****************************************************************************
45  * VLCVoutView interface
46  *****************************************************************************/
47 @interface VLCVoutView : NSView
48 {
49     vout_thread_t * p_vout;
50     NSView        * o_view;
51     NSRect        * s_frame;
52
53     vout_thread_t * p_real_vout;
54     id              o_window;
55 }
56 - (BOOL)setVout: (vout_thread_t *) p_arg_vout subView: (NSView *) view
57                      frame: (NSRect *) s_arg_frame;
58 - (void)closeVout;
59 - (void)updateTitle;
60 - (void)manage;
61 - (void)scaleWindowWithFactor: (float)factor;
62 - (void)setOnTop:(BOOL)b_on_top;
63 - (void)toggleFloatOnTop;
64 - (void)toggleFullscreen;
65 - (BOOL)isFullscreen;
66 - (void)snapshot;
67 - (id)getWindow;
68
69 + (id)getVoutView: (vout_thread_t *)p_vout subView: (NSView *) view
70                             frame: (NSRect *) s_frame;
71 + (vout_thread_t *)getRealVout: (vout_thread_t *)p_vout;
72
73 @end
74
75 /*****************************************************************************
76  * VLCVoutDetachedView interface
77  *****************************************************************************/
78
79 @interface VLCDetachedVoutView : VLCVoutView
80 {
81     mtime_t i_time_mouse_last_moved;
82 }
83
84 - (void)hideMouse: (BOOL)b_hide;
85
86 @end
87
88 /*****************************************************************************
89  * VLCEmbeddedView interface
90  *****************************************************************************/
91
92 @interface VLCEmbeddedVoutView : VLCVoutView
93 {
94     BOOL b_used;
95 }
96
97 - (void)setUsed: (BOOL)b_new_used;
98 - (BOOL)isUsed;
99
100 @end
101
102 /*****************************************************************************
103  * VLCDetachedEmbeddedView interface
104  *****************************************************************************/
105
106 @interface VLCDetachedEmbeddedVoutView : VLCEmbeddedVoutView
107 {
108 }
109
110 @end
111
112 /*****************************************************************************
113  * VLCWindow interface
114  *****************************************************************************/
115 @interface VLCWindow : NSWindow
116 {
117     vout_thread_t * p_vout;
118     VLCVoutView   * o_view;
119     NSRect        * s_frame;
120
121     vout_thread_t * p_real_vout;
122     Ptr             p_fullscreen_state;
123     vlc_bool_t      b_init_ok;
124     vlc_bool_t      b_black;
125 }
126
127 - (id) initWithVout: (vout_thread_t *) p_vout view: (VLCVoutView *) view
128                      frame: (NSRect *) s_frame;
129 - (id)initReal: (id) sender;
130 - (void)close;
131 - (void)closeWindow;
132 - (id)closeReal: (id) sender;
133 - (id)getVoutView;
134
135 - (BOOL)windowShouldClose:(id)sender;
136
137 @end