X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;ds=sidebyside;f=cinelerra-5.1%2Fcinelerra%2Fcolorpicker.h;h=2d69a92d8526b89491e29bdbede9dc952212a480;hb=1e154071bd323f756625f8172ef67133a561450a;hp=683fe13578ac33f435b7687094007b216bcaf460;hpb=30bdb85eb33a8ee7ba675038a86c6be59c43d7bd;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/cinelerra/colorpicker.h b/cinelerra-5.1/cinelerra/colorpicker.h index 683fe135..2d69a92d 100644 --- a/cinelerra-5.1/cinelerra/colorpicker.h +++ b/cinelerra-5.1/cinelerra/colorpicker.h @@ -2,26 +2,27 @@ /* * CINELERRA * Copyright (C) 2008 Adam Williams - * + * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. - * + * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * + * */ #ifndef COLORPICKER_H #define COLORPICKER_H +#include "bcdialog.h" #include "condition.inc" #include "guicast.h" #include "mutex.inc" @@ -40,37 +41,26 @@ class PaletteGreen; class PaletteBlue; class PaletteAlpha; -class ColorThread : public Thread +class ColorThread : public BC_DialogThread { public: - ColorThread(int do_alpha = 0, char *title = 0); + ColorThread(int do_alpha = 0, const char *title = 0); ~ColorThread(); - - void run(); - void start_window(int output, int alpha); + void start_window(int output, int alpha, int do_okcancel=0); virtual int handle_new_color(int output, int alpha); void update_gui(int output, int alpha); - ColorWindow* get_gui(); - -private: - friend class ColorWindow; + BC_Window* new_gui(); - ColorWindow *window; - Condition *completion; -// protects window, output, alpha - Mutex *mutex; -// Starting color - int output; - int alpha; - int do_alpha; - char *title; + int output, alpha; + int do_alpha, do_okcancel; + const char *title; }; class ColorWindow : public BC_Window { public: - ColorWindow(ColorThread *thread, int x, int y, char *title); + ColorWindow(ColorThread *thread, int x, int y, int w, int h, const char *title); void create_objects(); void change_values();