From 72eb091179afbdbec3ef5be10aaa109e6a4d11dd Mon Sep 17 00:00:00 2001 From: pbansal Date: Tue, 5 Mar 2019 14:03:21 +0530 Subject: [PATCH] 8214112: The whole text in target JPasswordField image are not selected Reviewed-by: serb, psadhukhan --- src/solaris/native/sun/awt/gtk3_interface.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/solaris/native/sun/awt/gtk3_interface.c b/src/solaris/native/sun/awt/gtk3_interface.c index 8e9d18596..e11ae1b92 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; -- GitLab