]> git.sesse.net Git - vlc/blob - modules/gui/macosx/SharedDialogs.h
macosx: add yosemite guard
[vlc] / modules / gui / macosx / SharedDialogs.h
1 /*****************************************************************************
2  * SharedDialogs.h: MacOS X interface module
3  *****************************************************************************
4  * Copyright (C) 2012 Felix Paul Kühne
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
26 @interface VLCEnterTextPanel : NSObject
27 {
28     IBOutlet id _panel;
29     IBOutlet id _title_lbl;
30     IBOutlet id _subtitle_lbl;
31     IBOutlet id _text_fld;
32     IBOutlet id _cancel_btn;
33     IBOutlet id _ok_btn;
34
35     NSString * _title;
36     NSString * _subtitle;
37     NSString * _okTitle;
38     NSString * _cancelTitle;
39     id _target;
40 }
41 + (VLCEnterTextPanel *)sharedInstance;
42
43 @property (readwrite, assign) NSString *title;
44 @property (readwrite, assign) NSString *subTitle;
45 @property (readwrite, assign) NSString *OKButtonLabel;
46 @property (readwrite, assign) NSString *CancelButtonLabel;
47 @property (readwrite, assign) id target;
48 @property (readonly) NSString *enteredText;
49
50 - (void)runModalForWindow:(NSWindow *)window;
51
52 - (IBAction)windowElementAction:(id)sender;
53
54 @end
55
56 @protocol VLCEnterTextPanel <NSObject>
57 @optional
58 - (void)panel:(VLCEnterTextPanel *)view returnValue:(NSUInteger)value text:(NSString *)text;
59 @end
60
61 @interface VLCSelectItemInPopupPanel : NSObject
62 {
63     IBOutlet id _panel;
64     IBOutlet id _title_lbl;
65     IBOutlet id _subtitle_lbl;
66     IBOutlet id _pop;
67     IBOutlet id _cancel_btn;
68     IBOutlet id _ok_btn;
69
70     NSString * _title;
71     NSString * _subtitle;
72     NSString * _okTitle;
73     NSString * _cancelTitle;
74     NSArray * _popData;
75
76     id _target;
77 }
78 + (VLCSelectItemInPopupPanel *)sharedInstance;
79
80 @property (readwrite, assign) NSString *title;
81 @property (readwrite, assign) NSString *subTitle;
82 @property (readwrite, assign) NSString *OKButtonLabel;
83 @property (readwrite, assign) NSString *CancelButtonLabel;
84 @property (readwrite, assign) NSArray *popupButtonContent;
85 @property (readwrite, assign) id target;
86 @property (readonly) NSUInteger currentItem;
87
88 - (void)runModalForWindow:(NSWindow *)window;
89
90 - (IBAction)windowElementAction:(id)sender;
91
92 @end
93
94 @protocol VLCSelectItemInPopupPanel <NSObject>
95 @optional
96 - (void)panel:(VLCSelectItemInPopupPanel *)panel returnValue:(NSUInteger)value item:(NSUInteger)item;
97 @end