[gtk+] gtkwidget: Remove unnecessary code in get_state_flags
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] gtkwidget: Remove unnecessary code in get_state_flags
- Date: Tue, 25 Nov 2014 19:08:45 +0000 (UTC)
commit 0c09d445091b2d16f92b3b3374d6b594015fac81
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Nov 24 16:56:23 2014 -0800
gtkwidget: Remove unnecessary code in get_state_flags
Any time has_focus is called, we will call gtk_widget_update_state_flags
which will assign the state flags properly.
gtk/gtkwidget.c | 9 +--------
1 files changed, 1 insertions(+), 8 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index fc5063c..7ff1aff 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -8857,16 +8857,9 @@ gtk_widget_unset_state_flags (GtkWidget *widget,
GtkStateFlags
gtk_widget_get_state_flags (GtkWidget *widget)
{
- GtkStateFlags flags;
-
g_return_val_if_fail (GTK_IS_WIDGET (widget), 0);
- flags = widget->priv->state_flags;
-
- if (gtk_widget_has_focus (widget))
- flags |= GTK_STATE_FLAG_FOCUSED;
-
- return flags;
+ return widget->priv->state_flags;
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]