[gtk/ebassi/new-a11y: 32/32] inspector: Support the a11y debug flag



commit e19adc47517028c24bc0fc029c2ddb314465568d
Author: Matthias Clasen <mclasen redhat com>
Date:   Fri Jul 17 10:40:31 2020 -0400

    inspector: Support the a11y debug flag
    
    Add support for the GTK_DEBUG_A11Y debug flag in
    the logs tab.

 gtk/inspector/logs.c  | 3 +++
 gtk/inspector/logs.ui | 6 ++++++
 2 files changed, 9 insertions(+)
---
diff --git a/gtk/inspector/logs.c b/gtk/inspector/logs.c
index ab24213762..c1dc9382e1 100644
--- a/gtk/inspector/logs.c
+++ b/gtk/inspector/logs.c
@@ -73,6 +73,7 @@ struct _GtkInspectorLogsPrivate
   GtkWidget *printing;
   GtkWidget *tree;
   GtkWidget *text;
+  GtkWidget *a11y;
 
   GdkDisplay *display;
 };
@@ -160,6 +161,7 @@ flag_toggled (GtkWidget        *button,
   update_flag (logs->priv->printing, &flags, GTK_DEBUG_PRINTING);
   update_flag (logs->priv->tree, &flags, GTK_DEBUG_TREE);
   update_flag (logs->priv->text, &flags, GTK_DEBUG_TEXT);
+  update_flag (logs->priv->a11y, &flags, GTK_DEBUG_A11Y);
   gtk_set_display_debug_flags (logs->priv->display, flags);
 }
 
@@ -201,6 +203,7 @@ gtk_inspector_logs_class_init (GtkInspectorLogsClass *klass)
   gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorLogs, printing);
   gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorLogs, tree);
   gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorLogs, text);
+  gtk_widget_class_bind_template_child_private (widget_class, GtkInspectorLogs, a11y);
   gtk_widget_class_bind_template_callback (widget_class, flag_toggled);
 }
 
diff --git a/gtk/inspector/logs.ui b/gtk/inspector/logs.ui
index a73ba03286..ee807d1c6a 100644
--- a/gtk/inspector/logs.ui
+++ b/gtk/inspector/logs.ui
@@ -215,6 +215,12 @@
                 <signal name="toggled" handler="flag_toggled"/>
               </object>
             </child>
+            <child>
+              <object class="GtkCheckButton" id="a11y">
+                <property name="label">Accessibility</property>
+                <signal name="toggled" handler="flag_toggled"/>
+              </object>
+            </child>
           </object>
         </child>
       </object>


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