[gtk/wip/carlosg/input-cleanups: 23/26] gtkwidget: Drop gtk_widget_device_is_shadowed()
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/carlosg/input-cleanups: 23/26] gtkwidget: Drop gtk_widget_device_is_shadowed()
- Date: Wed, 24 Jun 2020 18:38:25 +0000 (UTC)
commit f046e27bb4c04b60d2275d5fc56ef2a816f4dbec
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Jun 24 17:25:34 2020 +0200
gtkwidget: Drop gtk_widget_device_is_shadowed()
A widget no longer needs updating on GTK grabs on itself, drop
this miscellaneous and no longer used API.
docs/reference/gtk/gtk4-sections.txt | 1 -
gtk/gtkwidget.c | 42 ------------------------------------
gtk/gtkwidget.h | 4 ----
3 files changed, 47 deletions(-)
---
diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt
index 36983f7864..39e04bfb81 100644
--- a/docs/reference/gtk/gtk4-sections.txt
+++ b/docs/reference/gtk/gtk4-sections.txt
@@ -4503,7 +4503,6 @@ gtk_widget_set_receives_default
gtk_widget_get_receives_default
gtk_widget_get_realized
gtk_widget_get_mapped
-gtk_widget_device_is_shadowed
gtk_widget_get_opacity
gtk_widget_set_opacity
gtk_widget_get_overflow
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index fcd5bdec25..9376fc83c9 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -5218,48 +5218,6 @@ _gtk_widget_set_has_grab (GtkWidget *widget,
priv->has_grab = has_grab;
}
-/**
- * gtk_widget_device_is_shadowed:
- * @widget: a #GtkWidget
- * @device: a #GdkDevice
- *
- * Returns %TRUE if @device has been shadowed by a GTK+
- * device grab on another widget, so it would stop sending
- * events to @widget. This may be used in the
- * #GtkWidget::grab-notify signal to check for specific
- * devices. See gtk_device_grab_add().
- *
- * Returns: %TRUE if there is an ongoing grab on @device
- * by another #GtkWidget than @widget.
- **/
-gboolean
-gtk_widget_device_is_shadowed (GtkWidget *widget,
- GdkDevice *device)
-{
- GtkWindowGroup *group;
- GtkWidget *grab_widget;
- GtkRoot *root;
-
- g_return_val_if_fail (GTK_IS_WIDGET (widget), FALSE);
-
- if (!_gtk_widget_get_realized (widget))
- return TRUE;
-
- root = _gtk_widget_get_root (widget);
-
- if (GTK_IS_WINDOW (root))
- group = gtk_window_get_group (GTK_WINDOW (root));
- else
- group = gtk_window_get_group (NULL);
-
- grab_widget = gtk_window_group_get_current_grab (group);
- if (grab_widget && widget != grab_widget &&
- !gtk_widget_is_ancestor (widget, grab_widget))
- return TRUE;
-
- return FALSE;
-}
-
/**
* gtk_widget_set_name:
* @widget: a #GtkWidget
diff --git a/gtk/gtkwidget.h b/gtk/gtkwidget.h
index 5a5b92b501..cf812b9b26 100644
--- a/gtk/gtkwidget.h
+++ b/gtk/gtkwidget.h
@@ -427,10 +427,6 @@ void gtk_widget_set_receives_default (GtkWidget *widget,
GDK_AVAILABLE_IN_ALL
gboolean gtk_widget_get_receives_default (GtkWidget *widget);
-GDK_AVAILABLE_IN_ALL
-gboolean gtk_widget_device_is_shadowed (GtkWidget *widget,
- GdkDevice *device);
-
GDK_AVAILABLE_IN_ALL
void gtk_widget_set_name (GtkWidget *widget,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]