[gtk/wip/matthiasc/can-focus: 10/16] widget: Drop the :can-focus property
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/matthiasc/can-focus: 10/16] widget: Drop the :can-focus property
- Date: Mon, 30 Mar 2020 02:57:19 +0000 (UTC)
commit a8ef210a7fee15078a131b8ff7d6d5c956e31525
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Mar 29 20:59:47 2020 -0400
widget: Drop the :can-focus property
We still keep the setter around, for widget implementations.
gtk/gtkwidget.c | 16 ----------------
1 file changed, 16 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index a276b3369b..b3f02817c3 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -515,7 +515,6 @@ enum {
PROP_HEIGHT_REQUEST,
PROP_VISIBLE,
PROP_SENSITIVE,
- PROP_CAN_FOCUS,
PROP_HAS_FOCUS,
PROP_IS_FOCUS,
PROP_CAN_TARGET,
@@ -978,13 +977,6 @@ gtk_widget_class_init (GtkWidgetClass *klass)
TRUE,
GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY);
- widget_props[PROP_CAN_FOCUS] =
- g_param_spec_boolean ("can-focus",
- P_("Can focus"),
- P_("Whether the widget can accept the input focus"),
- FALSE,
- GTK_PARAM_READWRITE|G_PARAM_EXPLICIT_NOTIFY);
-
widget_props[PROP_HAS_FOCUS] =
g_param_spec_boolean ("has-focus",
P_("Has focus"),
@@ -1692,9 +1684,6 @@ gtk_widget_set_property (GObject *object,
case PROP_SENSITIVE:
gtk_widget_set_sensitive (widget, g_value_get_boolean (value));
break;
- case PROP_CAN_FOCUS:
- gtk_widget_set_can_focus (widget, g_value_get_boolean (value));
- break;
case PROP_HAS_FOCUS:
if (g_value_get_boolean (value))
gtk_widget_grab_focus (widget);
@@ -1850,9 +1839,6 @@ gtk_widget_get_property (GObject *object,
case PROP_SENSITIVE:
g_value_set_boolean (value, gtk_widget_get_sensitive (widget));
break;
- case PROP_CAN_FOCUS:
- g_value_set_boolean (value, gtk_widget_get_can_focus (widget));
- break;
case PROP_HAS_FOCUS:
g_value_set_boolean (value, gtk_widget_has_focus (widget));
break;
@@ -5013,9 +4999,7 @@ gtk_widget_set_can_focus (GtkWidget *widget,
if (priv->can_focus != can_focus)
{
priv->can_focus = can_focus;
-
gtk_widget_queue_resize (widget);
- g_object_notify_by_pspec (G_OBJECT (widget), widget_props[PROP_CAN_FOCUS]);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]