< prev index next >
src/java.desktop/unix/native/libawt_xawt/awt/gtk3_interface.c
Print this page
rev 16167 : 8170525: Fix minor issues in awt coding
*** 2012,2024 ****
/*************************************************/
static guint8 recode_color(gdouble channel)
{
guint16 result = (guint16)(channel * 65535);
! if (result < 0) {
! result = 0;
! } else if (result > 65535) {
result = 65535;
}
return (guint8)( result >> 8);
}
--- 2012,2022 ----
/*************************************************/
static guint8 recode_color(gdouble channel)
{
guint16 result = (guint16)(channel * 65535);
! if (result > 65535) {
result = 65535;
}
return (guint8)( result >> 8);
}
*** 2216,2225 ****
--- 2214,2224 ----
}
static GdkRGBA gtk3_get_color_for_flags(GtkStyleContext* context,
GtkStateFlags flags, ColorType color_type) {
GdkRGBA c, color;
+ color.alpha = 0;
switch (color_type)
{
case FOREGROUND:
case TEXT_FOREGROUND:
< prev index next >