4 * Copyright (C) 1997-2011 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 COLOR3WAYWINDOW_H
23 #define COLOR3WAYWINDOW_H
26 class Color3WayThread;
27 class Color3WayWindow;
28 class Color3WaySlider;
29 class Color3WayPreserve;
33 class Color3WayWindow;
40 #include "color3way.h"
41 #include "pluginclient.h"
44 class Color3WayPoint : public BC_SubWindow
47 Color3WayPoint(Color3WayMain *plugin,
56 virtual ~Color3WayPoint();
61 int cursor_enter_event();
62 int cursor_leave_event();
63 int cursor_motion_event();
64 int button_release_event();
65 int button_press_event();
66 void draw_face(int flash, int flush);
67 int reposition_window(int x, int y, int radius);
89 Color3WayMain *plugin;
96 BC_Pixmap *fg_images[COLOR_IMAGES];
101 class Color3WaySlider : public BC_FSlider
104 Color3WaySlider(Color3WayMain *plugin,
105 Color3WayWindow *gui,
115 Color3WayMain *plugin;
116 Color3WayWindow *gui;
120 char string[BCTEXTLEN];
124 class Color3WayResetSection : public BC_GenericButton
127 Color3WayResetSection(Color3WayMain *plugin,
128 Color3WayWindow *gui,
133 Color3WayMain *plugin;
134 Color3WayWindow *gui;
138 class Color3WayBalanceSection : public BC_GenericButton
141 Color3WayBalanceSection(Color3WayMain *plugin,
142 Color3WayWindow *gui,
147 Color3WayMain *plugin;
148 Color3WayWindow *gui;
152 class Color3WayCopySection : public BC_CheckBox
155 Color3WayCopySection(Color3WayMain *plugin,
156 Color3WayWindow *gui,
161 Color3WayMain *plugin;
162 Color3WayWindow *gui;
166 class Color3WaySection
169 Color3WaySection(Color3WayMain *plugin,
170 Color3WayWindow *gui,
176 void create_objects();
177 int reposition_window(int x, int y, int w, int h);
181 Color3WayMain *plugin;
182 Color3WayWindow *gui;
185 Color3WayPoint *point;
186 BC_Title *value_title;
187 Color3WaySlider *value;
189 Color3WaySlider *saturation;
190 Color3WayResetSection *reset;
191 Color3WayBalanceSection *balance;
192 Color3WayCopySection *copy;
196 class Color3WayWindow : public PluginClientWindow
199 Color3WayWindow(Color3WayMain *plugin);
202 void create_objects();
204 int resize_event(int w, int h);
206 Color3WayMain *plugin;
207 Color3WayPoint *active_point;
209 Color3WaySection *sections[SECTIONS];