]> git.sesse.net Git - vlc/blob - modules/gui/macosx/simple_prefs.h
macosx: fixed l10n of the Growl option
[vlc] / modules / gui / macosx / simple_prefs.h
1 /*****************************************************************************
2 * simple_prefs.h: Simple Preferences for Mac OS X
3 *****************************************************************************
4 * Copyright (C) 2008-2011 the VideoLAN team
5 * $Id$
6 *
7 * Authors: Felix Paul Kühne <fkuehne at videolan dot org>
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 * GNU General Public License for more details.
18 *
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
22 *****************************************************************************/
23
24 #import <Cocoa/Cocoa.h>
25 #import "intf.h"
26 #import <vlc_common.h>
27
28 @interface VLCSimplePrefs : NSObject <NSToolbarDelegate>
29 {
30     IBOutlet id o_audio_dolby_pop;
31     IBOutlet id o_audio_dolby_txt;
32     IBOutlet id o_audio_effects_box;
33     IBOutlet id o_audio_enable_ckb;
34     IBOutlet id o_audio_general_box;
35     IBOutlet id o_audio_lang_fld;
36     IBOutlet id o_audio_lang_txt;
37     IBOutlet id o_audio_last_box;
38     IBOutlet id o_audio_last_ckb;
39     IBOutlet id o_audio_lastpwd_sfld;
40     IBOutlet id o_audio_lastpwd_txt;
41     IBOutlet id o_audio_lastuser_fld;
42     IBOutlet id o_audio_lastuser_txt;
43     IBOutlet id o_audio_spdif_ckb;
44     IBOutlet id o_audio_view;
45     IBOutlet id o_audio_visual_pop;
46     IBOutlet id o_audio_visual_txt;
47     IBOutlet id o_audio_vol_fld;
48     IBOutlet id o_audio_vol_sld;
49     IBOutlet id o_audio_vol_txt;
50
51     IBOutlet id o_hotkeys_change_btn;
52     IBOutlet id o_hotkeys_change_lbl;
53     IBOutlet id o_hotkeys_change_keys_lbl;
54     IBOutlet id o_hotkeys_change_taken_lbl;
55     IBOutlet id o_hotkeys_change_win;
56     IBOutlet id o_hotkeys_change_cancel_btn;
57     IBOutlet id o_hotkeys_change_ok_btn;
58     IBOutlet id o_hotkeys_clear_btn;
59     IBOutlet id o_hotkeys_lbl;
60     IBOutlet id o_hotkeys_listbox;
61     IBOutlet id o_hotkeys_view;
62
63     IBOutlet id o_input_record_box;
64     IBOutlet id o_input_record_fld;
65     IBOutlet id o_input_record_btn;
66     IBOutlet id o_input_avi_pop;
67     IBOutlet id o_input_avi_txt;
68     IBOutlet id o_input_cachelevel_pop;
69     IBOutlet id o_input_cachelevel_txt;
70     IBOutlet id o_input_cachelevel_custom_txt;
71     IBOutlet id o_input_caching_box;
72     IBOutlet id o_input_httpproxy_fld;
73     IBOutlet id o_input_httpproxy_txt;
74     IBOutlet id o_input_httpproxypwd_sfld;
75     IBOutlet id o_input_httpproxypwd_txt;
76     IBOutlet id o_input_mux_box;
77     IBOutlet id o_input_net_box;
78     IBOutlet id o_input_postproc_fld;
79     IBOutlet id o_input_postproc_txt;
80     IBOutlet id o_input_rtsp_ckb;
81     IBOutlet id o_input_skipLoop_txt;
82     IBOutlet id o_input_skipLoop_pop;
83     IBOutlet id o_input_view;
84
85     IBOutlet id o_intf_style_txt;
86     IBOutlet id o_intf_style_dark_bcell;
87     IBOutlet id o_intf_style_bright_bcell;
88     IBOutlet id o_intf_art_pop;
89     IBOutlet id o_intf_art_txt;
90     IBOutlet id o_intf_embedded_ckb;
91     IBOutlet id o_intf_fspanel_ckb;
92         IBOutlet id o_intf_appleremote_ckb;
93         IBOutlet id o_intf_mediakeys_ckb;
94     IBOutlet id o_intf_lang_pop;
95     IBOutlet id o_intf_lang_txt;
96     IBOutlet id o_intf_network_box;
97     IBOutlet id o_intf_view;
98     IBOutlet id o_intf_update_ckb;
99     IBOutlet id o_intf_last_update_lbl;
100     IBOutlet id o_intf_enableGrowl_ckb;
101     IBOutlet id o_intf_nativefullscreen_ckb;
102
103     IBOutlet id o_osd_encoding_pop;
104     IBOutlet id o_osd_encoding_txt;
105     IBOutlet id o_osd_font_box;
106     IBOutlet id o_osd_font_btn;
107     IBOutlet id o_osd_font_color_pop;
108     IBOutlet id o_osd_font_color_txt;
109     IBOutlet id o_osd_font_fld;
110     IBOutlet id o_osd_font_size_pop;
111     IBOutlet id o_osd_font_size_txt;
112     IBOutlet id o_osd_font_txt;
113     IBOutlet id o_osd_lang_box;
114     IBOutlet id o_osd_lang_fld;
115     IBOutlet id o_osd_lang_txt;
116     IBOutlet id o_osd_opacity_txt;
117     IBOutlet id o_osd_opacity_fld;
118     IBOutlet id o_osd_opacity_sld;
119     IBOutlet id o_osd_forcebold_ckb;
120     IBOutlet id o_osd_moreoptions_txt;
121     IBOutlet id o_osd_osd_box;
122     IBOutlet id o_osd_osd_ckb;
123     IBOutlet id o_osd_view;
124
125     IBOutlet id o_sprefs_showAll_btn;
126     IBOutlet id o_sprefs_cancel_btn;
127     IBOutlet id o_sprefs_controls_box;
128     IBOutlet id o_sprefs_reset_btn;
129     IBOutlet id o_sprefs_save_btn;
130     IBOutlet id o_sprefs_win;
131
132     IBOutlet id o_video_black_ckb;
133     IBOutlet id o_video_device_pop;
134     IBOutlet id o_video_device_txt;
135     IBOutlet id o_video_display_box;
136     IBOutlet id o_video_enable_ckb;
137     IBOutlet id o_video_fullscreen_ckb;
138     IBOutlet id o_video_onTop_ckb;
139     IBOutlet id o_video_output_pop;
140     IBOutlet id o_video_output_txt;
141     IBOutlet id o_video_skipFrames_ckb;
142     IBOutlet id o_video_snap_box;
143     IBOutlet id o_video_snap_folder_btn;
144     IBOutlet id o_video_snap_folder_fld;
145     IBOutlet id o_video_snap_folder_txt;
146     IBOutlet id o_video_snap_format_pop;
147     IBOutlet id o_video_snap_format_txt;
148     IBOutlet id o_video_snap_prefix_fld;
149     IBOutlet id o_video_snap_prefix_txt;
150     IBOutlet id o_video_snap_seqnum_ckb;
151     IBOutlet id o_video_view;
152
153     BOOL b_audioSettingChanged;
154     BOOL b_intfSettingChanged;
155     BOOL b_videoSettingChanged;
156     BOOL b_osdSettingChanged;
157     BOOL b_inputSettingChanged;
158     BOOL b_hotkeyChanged;
159     id o_currentlyShownCategoryView;
160
161     NSOpenPanel *o_selectFolderPanel;
162     NSArray *o_hotkeyDescriptions;
163     NSArray *o_hotkeyNames;
164     NSArray *o_hotkeysNonUseableKeys;
165     NSMutableArray *o_hotkeySettings;
166     NSString *o_keyInTransition;
167
168     intf_thread_t *p_intf;
169 }
170 + (VLCSimplePrefs *)sharedInstance;
171 - (NSString *)OSXStringKeyToString:(NSString *)theString;
172
173 /* toolbar */
174 - (NSToolbarItem *) toolbar: (NSToolbar *)o_toolbar 
175       itemForItemIdentifier: (NSString *)o_itemIdent 
176   willBeInsertedIntoToolbar: (BOOL)b_willBeInserted;
177 - (NSArray *)toolbarDefaultItemIdentifiers: (NSToolbar *)toolbar;
178 - (NSArray *)toolbarAllowedItemIdentifiers: (NSToolbar *)toolbar;
179
180 - (void)initStrings;
181 - (void)resetControls;
182 - (void)showSimplePrefs;
183
184 - (IBAction)buttonAction:(id)sender;
185 - (void)sheetDidEnd:(NSWindow *)o_sheet 
186          returnCode:(int)i_return
187         contextInfo:(void *)o_context;
188
189 - (void)saveChangedSettings;
190
191 /* interface */
192 - (IBAction)interfaceSettingChanged:(id)sender;
193 - (void)showInterfaceSettings;
194
195 /* audio */
196 - (IBAction)audioSettingChanged:(id)sender;
197 - (void)showAudioSettings;
198
199 /* video */
200 - (IBAction)videoSettingChanged:(id)sender;
201 - (void)showVideoSettings;
202
203 /* OSD / subtitles */
204 - (IBAction)osdSettingChanged:(id)sender;
205 - (IBAction)showFontPicker:(id)sender;
206 - (void)showOSDSettings;
207 - (void)changeFont:(id)sender;
208
209 /* input & codecs */
210 - (IBAction)inputSettingChanged:(id)sender;
211 - (void)showInputSettings;
212
213 /* hotkeys */
214 - (IBAction)hotkeySettingChanged:(id)sender;
215 - (void)showHotkeySettings;
216 - (int)numberOfRowsInTableView:(NSTableView *)aTableView;
217 - (id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex;
218 - (BOOL)changeHotkeyTo: (NSString *)theKey;
219
220 @end
221
222 @interface VLCHotkeyChangeWindow : NSWindow
223
224 @end
225
226 @interface VLCSimplePrefsWindow : NSWindow
227
228 @end