[gtk/wip/baedert/for-master: 13/17] label: Remove mnemonics_visible_apply_recursively from private header




commit 4326c5111a1d7825aeb3cc36df78ba008e3ea963
Author: Timm Bäder <mail baedert org>
Date:   Fri Dec 25 12:07:08 2020 +0100

    label: Remove mnemonics_visible_apply_recursively from private header
    
    This is only used in gtklabel.c

 gtk/gtklabel.c        | 59 ++++++++++++++++++++++++++-------------------------
 gtk/gtklabelprivate.h |  2 --
 2 files changed, 30 insertions(+), 31 deletions(-)
---
diff --git a/gtk/gtklabel.c b/gtk/gtklabel.c
index ef655b29e1..f4920c8667 100644
--- a/gtk/gtklabel.c
+++ b/gtk/gtklabel.c
@@ -2641,6 +2641,36 @@ gtk_label_new_with_mnemonic (const char *str)
   return GTK_WIDGET (self);
 }
 
+static void
+_gtk_label_mnemonics_visible_apply_recursively (GtkWidget *widget,
+                                                gboolean   visible)
+{
+  if (GTK_IS_LABEL (widget))
+    {
+      GtkLabel *self = GTK_LABEL (widget);
+
+      if (self->mnemonics_visible != visible)
+        {
+          self->mnemonics_visible = visible;
+          gtk_label_recalculate (self);
+        }
+    }
+  else
+    {
+      GtkWidget *child;
+
+      for (child = gtk_widget_get_first_child (widget);
+           child;
+           child = gtk_widget_get_next_sibling (child))
+        {
+          if (GTK_IS_NATIVE (child))
+            continue;
+
+          _gtk_label_mnemonics_visible_apply_recursively (child, visible);
+        }
+    }
+}
+
 static void
 label_mnemonics_visible_changed (GtkWidget  *widget,
                                  GParamSpec *pspec,
@@ -2712,35 +2742,6 @@ gtk_label_setup_mnemonic (GtkLabel *self)
     }
 }
 
-void
-_gtk_label_mnemonics_visible_apply_recursively (GtkWidget *widget,
-                                                gboolean   visible)
-{
-  if (GTK_IS_LABEL (widget))
-    {
-      GtkLabel *self = GTK_LABEL (widget);
-
-      if (self->mnemonics_visible != visible)
-        {
-          self->mnemonics_visible = visible;
-          gtk_label_recalculate (self);
-        }
-    }
-  else
-    {
-      GtkWidget *child;
-
-      for (child = gtk_widget_get_first_child (widget);
-           child;
-           child = gtk_widget_get_next_sibling (child))
-        {
-          if (GTK_IS_NATIVE (child))
-            continue;
-
-          _gtk_label_mnemonics_visible_apply_recursively (child, visible);
-        }
-    }
-}
 static void
 label_mnemonic_widget_weak_notify (gpointer      data,
                                    GObject      *where_the_object_was)
diff --git a/gtk/gtklabelprivate.h b/gtk/gtklabelprivate.h
index 68ecc1a1e3..8eb73d3af0 100644
--- a/gtk/gtklabelprivate.h
+++ b/gtk/gtklabelprivate.h
@@ -24,8 +24,6 @@
 
 G_BEGIN_DECLS
 
-void _gtk_label_mnemonics_visible_apply_recursively (GtkWidget *widget,
-                                                     gboolean   mnemonics_visible);
 int _gtk_label_get_cursor_position (GtkLabel *label);
 int _gtk_label_get_selection_bound (GtkLabel *label);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]