diff --git a/src/solaris/native/sun/awt/gtk3_interface.c b/src/solaris/native/sun/awt/gtk3_interface.c index 8e9d18596997bb39de9e716ec1708cf8dac6604a..e11ae1b92478b53e845b2fa5d8aaf97d1f14806c 100644 --- a/src/solaris/native/sun/awt/gtk3_interface.c +++ b/src/solaris/native/sun/awt/gtk3_interface.c @@ -2356,9 +2356,11 @@ static gint gtk3_get_color_for_state(JNIEnv *env, WidgetType widget_type, init_containers(); - if (widget_type == TEXT_FIELD && state_type == GTK_STATE_SELECTED && - color_type == TEXT_BACKGROUND) { - widget_type = TEXT_AREA; + if (gtk3_version_3_20) { + if ((widget_type == TEXT_FIELD || widget_type == PASSWORD_FIELD || widget_type == SPINNER_TEXT_FIELD || + widget_type == FORMATTED_TEXT_FIELD) && state_type == GTK_STATE_SELECTED && color_type == TEXT_BACKGROUND) { + widget_type = TEXT_AREA; + } } GtkStyleContext* context = NULL;