forked from AuroraMiddleware/gtk
gtk: don't always invalidate spinbuttons on each leave_notify()
but only when an arrow was prelighted. Also, chain up unconditonally in enter_notify() and leave_notify() because GtkEntry implements them too.
This commit is contained in:
parent
97d1f1d16f
commit
68d176d80b
@ -1115,10 +1115,7 @@ gtk_spin_button_enter_notify (GtkWidget *widget,
|
||||
gtk_widget_queue_draw (GTK_WIDGET (spin));
|
||||
}
|
||||
|
||||
if (GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->enter_notify_event)
|
||||
return GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->enter_notify_event (widget, event);
|
||||
|
||||
return FALSE;
|
||||
return GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->enter_notify_event (widget, event);
|
||||
}
|
||||
|
||||
static gint
|
||||
@ -1128,13 +1125,13 @@ gtk_spin_button_leave_notify (GtkWidget *widget,
|
||||
GtkSpinButton *spin = GTK_SPIN_BUTTON (widget);
|
||||
GtkSpinButtonPrivate *priv = spin->priv;
|
||||
|
||||
priv->in_child = NO_ARROW;
|
||||
gtk_widget_queue_draw (GTK_WIDGET (spin));
|
||||
if (priv->in_child != NO_ARROW)
|
||||
{
|
||||
priv->in_child = NO_ARROW;
|
||||
gtk_widget_queue_draw (GTK_WIDGET (spin));
|
||||
}
|
||||
|
||||
if (GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->leave_notify_event)
|
||||
return GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->leave_notify_event (widget, event);
|
||||
|
||||
return FALSE;
|
||||
return GTK_WIDGET_CLASS (gtk_spin_button_parent_class)->leave_notify_event (widget, event);
|
||||
}
|
||||
|
||||
static gint
|
||||
|
Loading…
Reference in New Issue
Block a user