X-Git-Url: https://git.cinelerra-gg.org/git/?p=goodguy%2Fcinelerra.git;a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fcolorpicker.C;h=fd796bfcaef64b158ad34396ecb75e58a8f7a7e3;hp=348817c4bac2915f44f10dd963d3e1ade73bba37;hb=HEAD;hpb=0b751b07a28e84a721b2bb76083db6629aa26d73 diff --git a/cinelerra-5.1/cinelerra/colorpicker.C b/cinelerra-5.1/cinelerra/colorpicker.C index 348817c4..b1e2a949 100644 --- a/cinelerra-5.1/cinelerra/colorpicker.C +++ b/cinelerra-5.1/cinelerra/colorpicker.C @@ -109,6 +109,8 @@ ColorWindow::ColorWindow(ColorPicker *thread, int x, int y, int w, int h, const ColorGUI(this) { this->thread = thread; +// *** CONTEXT_HELP *** + context_help_set_keyword("Title"); } ColorWindow::~ColorWindow() @@ -156,7 +158,6 @@ ColorGUI::ColorGUI(BC_WindowBase *window) hue = 0; sat = 0; val = 0; red = 0; grn = 0; blu = 0; lum = 0; c_r = 0; c_b = 0; - alpha = 0; hsv_h = 0; hsv_s = 0; hsv_v = 0; rgb_r = 0; rgb_g = 0; rgb_b = 0; @@ -1451,7 +1452,8 @@ void ColorBoxButton::create_objects() void ColorBoxButton::set_color(int color) { this->color = (color & 0xffffff); - this->alpha = (~color>>24) & 0xff; + if( this->alpha >= 0 ) + this->alpha = (~color>>24) & 0xff; int r = (color>>16) & 0xff; int g = (color>> 8) & 0xff; int b = (color>> 0) & 0xff; @@ -1513,7 +1515,8 @@ void ColorCircleButton::create_objects() void ColorCircleButton::set_color(int color) { this->color = (color & 0xffffff); - this->alpha = (~color>>24) & 0xff; + if( this->alpha >= 0 ) + this->alpha = (~color>>24) & 0xff; int r = (color>>16) & 0xff; int g = (color>>8) & 0xff; int b = (color>>0) & 0xff;