X-Git-Url: https://git.cinelerra-gg.org/git/?p=goodguy%2Fcinelerra.git;a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fcolorpicker.C;h=7238d59d043a2adab7472bba5b5ef91e4565626f;hp=f36374669e8185d503ed1065693739e67586e2f0;hb=d72d54c0e9d75486bb003e256630c77f77ce6368;hpb=686bc04a488847170d80ec603f8c33962a7aa928 diff --git a/cinelerra-5.1/cinelerra/colorpicker.C b/cinelerra-5.1/cinelerra/colorpicker.C index f3637466..7238d59d 100644 --- a/cinelerra-5.1/cinelerra/colorpicker.C +++ b/cinelerra-5.1/cinelerra/colorpicker.C @@ -1342,7 +1342,8 @@ void ColorBoxButton::create_objects() void ColorBoxButton::set_color(int color) { - this->color = color; + this->color = (color & 0xffffff); + this->alpha = (~color>>24) & 0xff; int r = (color>>16) & 0xff; int g = (color>> 8) & 0xff; int b = (color>> 0) & 0xff; @@ -1403,7 +1404,8 @@ void ColorCircleButton::create_objects() void ColorCircleButton::set_color(int color) { - this->color = color; + this->color = (color & 0xffffff); + this->alpha = (~color>>24); int r = (color>>16) & 0xff; int g = (color>>8) & 0xff; int b = (color>>0) & 0xff;