gtkspinbutton: Don't hilight buttons when !editable

Don't hilight the buttons on mouse over when 'editable' property is set to
'FALSE.

https://bugzilla.gnome.org/show_bug.cgi?id=667229
This commit is contained in:
Zeeshan Ali (Khattak) 2012-01-05 03:09:27 +02:00
parent e2dd95aced
commit 1996618569

View File

@ -816,7 +816,8 @@ gtk_spin_button_panel_get_state (GtkSpinButton *spin_button,
GtkStateFlags state;
GtkSpinButtonPrivate *priv = spin_button->priv;
if (gtk_spin_button_panel_at_limit (spin_button, panel))
if (gtk_spin_button_panel_at_limit (spin_button, panel) ||
!gtk_editable_get_editable (GTK_EDITABLE (spin_button)))
state = GTK_STATE_FLAG_INSENSITIVE;
else
{