From 403dc26c95b7d2b3a57eef535d14ff38ab653d7e Mon Sep 17 00:00:00 2001 From: Dodji Seketeli Date: Sun, 29 Feb 2004 14:29:40 +0000 Subject: fixed a stupid bug here. 2004-02-29 Dodji Seketeli * src/cr-rgb.c: (cr_rgb_set): fixed a stupid bug here. --- ChangeLog | 5 +++++ src/cr-rgb.c | 15 +-------------- 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index 150f214..5d82c73 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-02-29 Dodji Seketeli + + * src/cr-rgb.c: + (cr_rgb_set): fixed a stupid bug here. + 2004-02-29 Dodji Seketeli * src/cr-sel-eng.c: applied a patch of Rob BUIS diff --git a/src/cr-rgb.c b/src/cr-rgb.c index 5999d23..011c653 100644 --- a/src/cr-rgb.c +++ b/src/cr-rgb.c @@ -304,8 +304,6 @@ cr_rgb_dump (CRRgb *a_this, FILE *a_fp) /** *Sets rgb values to the RGB. - *If the rgb values are percentages, make - *sure that the sum of the 3 values makes 100%. *@param a_this the current instance of #CRRgb. *@param a_red the red value. *@param a_green the green value. @@ -331,18 +329,7 @@ cr_rgb_set (CRRgb *a_this, gulong a_red, a_this->red = a_red ; a_this->green = a_green ; - if (a_is_percentage != FALSE) - { - if (a_red + a_green >= 100) - { - a_green = 100 - a_red ; - } - a_this->blue = 100 - a_red - a_green ; - } - else - { - a_this->blue = a_blue ; - } + a_this->blue = a_blue ; return CR_OK ; } -- cgit v1.2.1