devel Makefile fix, prefs appearance tab/rework, picon stratigy, edl path fix, change...
[goodguy/history.git] / cinelerra-5.1 / cinelerra / interfaceprefs.h
1
2 /*
3  * CINELERRA
4  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  *
20  */
21
22 #ifndef INTERFACEPREFS_H
23 #define INTERFACEPREFS_H
24
25 #include "browsebutton.h"
26 #include "deleteallindexes.inc"
27 #include "interfaceprefs.inc"
28 #include "mwindow.inc"
29 #include "preferencesthread.h"
30 #include "probeprefs.inc"
31 #include "shbtnprefs.inc"
32
33
34 class InterfacePrefs : public PreferencesDialog
35 {
36 public:
37         InterfacePrefs(MWindow *mwindow, PreferencesWindow *pwindow);
38         ~InterfacePrefs();
39
40         void create_objects();
41 // must delete each derived class
42         int update(int new_value);
43         const char* behavior_to_text(int mode);
44         int start_shbtn_dialog();
45         void start_probe_dialog();
46
47         BrowseButton *ipath;
48         IndexSize *isize;
49         IndexCount *icount;
50         IndexPathText *ipathtext;
51         DeleteAllIndexes *deleteall;
52         IndexFFMPEGMarkerFiles *ffmpeg_marker_files;
53
54         ViewBehaviourText *button1, *button2, *button3;
55         MeterMinDB *min_db;
56         MeterMaxDB *max_db;
57
58         ShBtnEditDialog *shbtn_dialog;
59         KeyframeReticle *keyframe_reticle;
60         PrefsYUV420P_DVDlace *yuv420p_dvdlace;
61         FileProbeDialog *file_probe_dialog;
62         PrefsFileProbes *file_probes;
63         PrefsTrapSigSEGV *trap_segv;
64         PrefsTrapSigINTR *trap_intr;
65 };
66
67
68 class IndexPathText : public BC_TextBox
69 {
70 public:
71         IndexPathText(int x, int y, PreferencesWindow *pwindow, char *text);
72         ~IndexPathText();
73         int handle_event();
74         PreferencesWindow *pwindow;
75 };
76
77 class IndexSize : public BC_TextBox
78 {
79 public:
80         IndexSize(int x, int y, PreferencesWindow *pwindow, char *text);
81         int handle_event();
82         PreferencesWindow *pwindow;
83 };
84
85
86 class IndexCount : public BC_TextBox
87 {
88 public:
89         IndexCount(int x, int y, PreferencesWindow *pwindow, char *text);
90         int handle_event();
91         PreferencesWindow *pwindow;
92 };
93
94
95 class ViewBehaviourText : public BC_PopupMenu
96 {
97 public:
98         ViewBehaviourText(int x, int y, const char *text,
99                 PreferencesWindow *pwindow, int *output);
100         ~ViewBehaviourText();
101
102         int handle_event();  // user copies text to value here
103         void create_objects();         // add initial items
104         InterfacePrefs *tfwindow;
105         int *output;
106 };
107
108 class ViewBehaviourItem : public BC_MenuItem
109 {
110 public:
111         ViewBehaviourItem(ViewBehaviourText *popup, char *text, int behaviour);
112         ~ViewBehaviourItem();
113
114         int handle_event();
115         ViewBehaviourText *popup;
116         int behaviour;
117 };
118
119
120 class MeterMinDB : public BC_TextBox
121 {
122 public:
123         MeterMinDB(PreferencesWindow *pwindow, char *text, int x, int y);
124         int handle_event();
125         PreferencesWindow *pwindow;
126 };
127
128
129 class MeterMaxDB : public BC_TextBox
130 {
131 public:
132         MeterMaxDB(PreferencesWindow *pwindow, char *text, int x, int y);
133         int handle_event();
134         PreferencesWindow *pwindow;
135 };
136
137 class ScanCommercials : public BC_CheckBox
138 {
139 public:
140         ScanCommercials(PreferencesWindow *pwindow, int x, int y);
141         int handle_event();
142         PreferencesWindow *pwindow;
143 };
144
145 class AndroidRemote : public BC_CheckBox
146 {
147 public:
148         AndroidRemote(PreferencesWindow *pwindow, int x, int y);
149         int handle_event();
150         PreferencesWindow *pwindow;
151 };
152
153 class AndroidPIN : public BC_TextBox
154 {
155 public:
156         PreferencesWindow *pwindow;
157         int handle_event();
158         AndroidPIN(PreferencesWindow *pwindow, int x, int y);
159 };
160
161 class AndroidPort : public BC_TextBox
162 {
163 public:
164         PreferencesWindow *pwindow;
165         int handle_event();
166         AndroidPort(PreferencesWindow *pwindow, int x, int y);
167 };
168
169 class ShBtnPrefs : public BC_GenericButton
170 {
171 public:
172         PreferencesWindow *pwindow;
173         InterfacePrefs *iface_prefs;
174
175         int handle_event();
176         ShBtnPrefs(PreferencesWindow *pwindow, InterfacePrefs *iface_prefs, int x, int y);
177 };
178 class StillImageUseDuration : public BC_CheckBox
179 {
180 public:
181         StillImageUseDuration(PreferencesWindow *pwindow, int value, int x, int y);
182         int handle_event();
183         PreferencesWindow *pwindow;
184 };
185
186 class StillImageDuration : public BC_TextBox
187 {
188 public:
189         StillImageDuration(PreferencesWindow *pwindow, int x, int y);
190         int handle_event();
191         PreferencesWindow *pwindow;
192 };
193
194 class KeyframeReticle : public BC_PopupMenu
195 {
196 public:
197         KeyframeReticle(int x, int y, int *output);
198         ~KeyframeReticle();
199
200         const char* hairline_to_string(int type);
201         void create_objects();
202         int *output;
203 };
204
205 class HairlineItem : public BC_MenuItem
206 {
207 public:
208         HairlineItem(KeyframeReticle *popup, int hairline);
209         ~HairlineItem();
210
211         KeyframeReticle *popup;
212         int handle_event();
213         int hairline;
214 };
215
216 class IndexFFMPEGMarkerFiles : public BC_CheckBox
217 {
218 public:
219         IndexFFMPEGMarkerFiles(InterfacePrefs *iface_prefs, int x, int y);
220         ~IndexFFMPEGMarkerFiles();
221
222         int handle_event();
223
224         InterfacePrefs *iface_prefs;
225 };
226
227
228 class PrefsTrapSigSEGV : public BC_CheckBox
229 {
230 public:
231         PrefsTrapSigSEGV(InterfacePrefs *subwindow, int x, int y);
232         ~PrefsTrapSigSEGV();
233         int handle_event();
234
235         InterfacePrefs *subwindow;
236 };
237
238 class PrefsTrapSigINTR : public BC_CheckBox
239 {
240 public:
241         PrefsTrapSigINTR(InterfacePrefs *subwindow, int x, int y);
242         ~PrefsTrapSigINTR();
243         int handle_event();
244
245         InterfacePrefs *subwindow;
246 };
247
248
249 class PrefsFileProbes : public BC_GenericButton
250 {
251 public:
252         PreferencesWindow *pwindow;
253         InterfacePrefs *subwindow;
254
255         int handle_event();
256         PrefsFileProbes(PreferencesWindow *pwindow, InterfacePrefs *subwindow, int x, int y);
257 };
258
259
260 class PrefsYUV420P_DVDlace : public BC_CheckBox
261 {
262 public:
263         PrefsYUV420P_DVDlace(PreferencesWindow *pwindow,
264                 InterfacePrefs *subwindow, int x, int y);
265         int handle_event();
266
267         InterfacePrefs *subwindow;
268         PreferencesWindow *pwindow;
269 };
270
271
272 #endif