edit group selection and cut/copy/paste/del shortcuts, interview mode tweaks
[goodguy/cinelerra.git] / cinelerra-5.1 / cinelerra / editpopup.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 EDITPOPUP_H
23 #define EDITPOPUP_H
24
25 #include "guicast.h"
26 #include "edit.inc"
27 #include "editpopup.inc"
28 #include "mwindow.inc"
29 #include "mwindowgui.inc"
30 #include "plugindialog.inc"
31 #include "resizetrackthread.inc"
32
33 class EditPopup : public BC_PopupMenu
34 {
35 public:
36         EditPopup(MWindow *mwindow, MWindowGUI *gui);
37         ~EditPopup();
38
39         void create_objects();
40         int update(Edit *edit);
41
42         MWindow *mwindow;
43         MWindowGUI *gui;
44         Edit *edit;
45 };
46
47
48 class EditPopupClear : public BC_MenuItem
49 {
50 public:
51         EditPopupClear(MWindow *mwindow, EditPopup *popup);
52         int handle_event();
53
54         MWindow *mwindow;
55         EditPopup *popup;
56 };
57
58 class EditPopupDelete : public BC_MenuItem
59 {
60 public:
61         EditPopupDelete(MWindow *mwindow, EditPopup *popup);
62         int handle_event();
63
64         MWindow *mwindow;
65         EditPopup *popup;
66 };
67
68 class EditPopupCopy : public BC_MenuItem
69 {
70 public:
71         EditPopupCopy(MWindow *mwindow, EditPopup *popup);
72         int handle_event();
73
74         MWindow *mwindow;
75         EditPopup *popup;
76 };
77
78 class EditPopupCut : public BC_MenuItem
79 {
80 public:
81         EditPopupCut(MWindow *mwindow, EditPopup *popup);
82         int handle_event();
83
84         MWindow *mwindow;
85         EditPopup *popup;
86 };
87
88 class EditPopupCopyCut : public BC_MenuItem
89 {
90 public:
91         EditPopupCopyCut(MWindow *mwindow, EditPopup *popup);
92         int handle_event();
93
94         MWindow *mwindow;
95         EditPopup *popup;
96 };
97
98 class EditPopupPaste : public BC_MenuItem
99 {
100 public:
101         EditPopupPaste(MWindow *mwindow, EditPopup *popup);
102         int handle_event();
103
104         MWindow *mwindow;
105         EditPopup *popup;
106 };
107
108 class EditPopupFindAsset : public BC_MenuItem
109 {
110 public:
111         EditPopupFindAsset(MWindow *mwindow, EditPopup *popup);
112         int handle_event();
113         MWindow *mwindow;
114         EditPopup *popup;
115 };
116
117 class EditPopupTitle : public BC_MenuItem
118 {
119 public:
120         EditPopupTitle(MWindow *mwindow, EditPopup *popup);
121         ~EditPopupTitle();
122
123         int handle_event();
124
125         MWindow *mwindow;
126         EditPopup *popup;
127         EditTitleDialogThread *dialog_thread;
128 };
129
130 class EditTitleDialogThread : public BC_DialogThread
131 {
132 public:
133         EditTitleDialogThread(EditPopupTitle *edit_title);
134         ~EditTitleDialogThread();
135         BC_Window* new_gui();
136         void start(int wx, int wy);
137         void handle_close_event(int result);
138         void handle_done_event(int result);
139
140         int wx, wy;
141         EditPopupTitle *edit_title;
142         EditPopupTitleWindow *window;
143 };
144
145 class EditPopupTitleText : public BC_TextBox
146 {
147 public:
148         EditPopupTitleText(EditPopupTitleWindow *window,
149                 MWindow *mwindow, int x, int y, const char *text);
150         ~EditPopupTitleText();
151         int handle_event();
152
153         MWindow *mwindow;
154         EditPopupTitleWindow *window;
155 };
156
157 class EditPopupTitleWindow : public BC_Window
158 {
159 public:
160         EditPopupTitleWindow(MWindow *mwindow, EditPopup *popup, int wx, int wy);
161         ~EditPopupTitleWindow();
162
163         void create_objects();
164         void handle_close_event(int result);
165
166         EditPopupTitleText *title_text;
167         MWindow *mwindow;
168         EditPopup *popup;
169         char new_text[BCTEXTLEN];
170 };
171
172
173 class EditPopupShow : public BC_MenuItem
174 {
175 public:
176         EditPopupShow(MWindow *mwindow, EditPopup *popup);
177         ~EditPopupShow();
178
179         int handle_event();
180
181         MWindow *mwindow;
182         EditPopup *popup;
183         EditShowDialogThread *dialog_thread;
184 };
185
186 class EditShowDialogThread : public BC_DialogThread
187 {
188 public:
189         EditShowDialogThread(EditPopupShow *edit_show);
190         ~EditShowDialogThread();
191         BC_Window* new_gui();
192         void start(int wx, int wy);
193         void handle_close_event(int result);
194
195         int wx, wy;
196         EditPopupShow *edit_show;
197         EditPopupShowWindow *window;
198 };
199
200 class EditPopupShowText : public BC_TextBox
201 {
202 public:
203         EditPopupShowText(EditPopupShowWindow *window,
204                 MWindow *mwindow, int x, int y, const char *text);
205         ~EditPopupShowText();
206
207         EditPopupShowWindow *window;
208         MWindow *mwindow;
209 };
210
211 class EditPopupShowWindow : public BC_Window
212 {
213 public:
214         EditPopupShowWindow(MWindow *mwindow, EditPopup *popup, int wx, int wy);
215         ~EditPopupShowWindow();
216
217         void create_objects();
218
219         EditPopupShowText *show_text;
220         MWindow *mwindow;
221         EditPopup *popup;
222 };
223
224 #endif