4 * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
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.
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.
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
22 #ifndef RESIZETRACKTHREAD_H
23 #define RESIZETRACKTHREAD_H
30 #include "assetedit.inc"
33 #include "mwindow.inc"
38 class ResizeVTrackWindow;
40 class ResizeVTrackThread : public Thread
43 ResizeVTrackThread(MWindow *mwindow);
44 ~ResizeVTrackThread();
46 void start_window(int w, int h, int w1, int h1);
48 virtual void update() {}
50 ResizeVTrackWindow *window;
54 double w_scale, h_scale;
59 class ResizeVTrackWindow;
62 class ResizeVTrackWidth : public BC_TextBox
65 ResizeVTrackWidth(ResizeVTrackWindow *gui,
66 ResizeVTrackThread *thread,
70 ResizeVTrackWindow *gui;
71 ResizeVTrackThread *thread;
74 class ResizeVTrackSwap : public BC_Button
77 ResizeVTrackSwap(ResizeVTrackWindow *gui,
78 ResizeVTrackThread *thread,
82 ResizeVTrackWindow *gui;
83 ResizeVTrackThread *thread;
86 class ResizeVTrackHeight : public BC_TextBox
89 ResizeVTrackHeight(ResizeVTrackWindow *gui,
90 ResizeVTrackThread *thread,
94 ResizeVTrackWindow *gui;
95 ResizeVTrackThread *thread;
99 class ResizeVTrackScaleW : public BC_TextBox
102 ResizeVTrackScaleW(ResizeVTrackWindow *gui,
103 ResizeVTrackThread *thread,
107 ResizeVTrackWindow *gui;
108 ResizeVTrackThread *thread;
111 class ResizeVTrackScaleH : public BC_TextBox
114 ResizeVTrackScaleH(ResizeVTrackWindow *gui,
115 ResizeVTrackThread *thread,
119 ResizeVTrackWindow *gui;
120 ResizeVTrackThread *thread;
124 class ResizeVTrackWindow : public BC_Window
127 ResizeVTrackWindow(MWindow *mwindow,
128 ResizeVTrackThread *thread,
131 ~ResizeVTrackWindow();
133 void create_objects();
134 void update(int changed_scale,
139 ResizeVTrackThread *thread;
140 ResizeVTrackWidth *w;
141 ResizeVTrackHeight *h;
142 ResizeVTrackScaleW *w_scale;
143 ResizeVTrackScaleH *h_scale;
147 class ResizeTrackThread : public ResizeVTrackThread
150 ResizeTrackThread(MWindow *mwindow);
151 ~ResizeTrackThread();
153 void start_window(Track *track);
159 class ResizeAssetThread : public ResizeVTrackThread
162 ResizeAssetThread(AssetEditWindow *fwindow);
163 ~ResizeAssetThread();
165 void start_window(Asset *asset);
168 AssetEditWindow *fwindow;
172 class ResizeAssetButton : public BC_GenericButton
175 ResizeAssetButton(AssetEditWindow *fwindow, int x, int y);
176 ~ResizeAssetButton();
180 ResizeAssetThread *resize_asset_thread;
181 AssetEditWindow *fwindow;