[gtk/gtk-4-2: 58/91] a11y: Realize notebook tabs when switching
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/gtk-4-2: 58/91] a11y: Realize notebook tabs when switching
- Date: Tue, 4 May 2021 02:05:41 +0000 (UTC)
commit 7e3493b15e04b5433ccd5757fd464ba222171c9d
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Apr 20 20:35:22 2021 -0400
a11y: Realize notebook tabs when switching
We're not moving focus here, so we can't rely
on that to conjure the a11y objects into existence.
gtk/gtknotebook.c | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 380cd51e5e..aa89cf6067 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -5461,6 +5461,9 @@ gtk_notebook_real_switch_page (GtkNotebook *notebook,
gtk_widget_set_state_flags (page->tab_widget, GTK_STATE_FLAG_CHECKED, FALSE);
gtk_widget_set_visible (notebook->header_widget, notebook->show_tabs);
+ if (gtk_widget_get_realized (GTK_WIDGET (notebook)))
+ gtk_widget_realize_at_context (notebook->cur_page->tab_widget);
+
gtk_accessible_update_state (GTK_ACCESSIBLE (notebook->cur_page->tab_widget),
GTK_ACCESSIBLE_STATE_SELECTED, TRUE,
-1);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]