[gtk+/native-layout] Fix missing GTK_WINDOW cast in _gtk_menu_shell_update_mnemonics
- From: Tristan Van Berkom <tvb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/native-layout] Fix missing GTK_WINDOW cast in _gtk_menu_shell_update_mnemonics
- Date: Sun, 4 Apr 2010 02:14:34 +0000 (UTC)
commit ea7bd00e925f6ef6e68189d4474011853aff9b33
Author: Christian Dywan <christian twotoasts de>
Date: Mon Jan 4 07:29:42 2010 +0100
Fix missing GTK_WINDOW cast in _gtk_menu_shell_update_mnemonics
gtk/gtkmenushell.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c
index db3a9f9..c9b8949 100644
--- a/gtk/gtkmenushell.c
+++ b/gtk/gtkmenushell.c
@@ -805,6 +805,8 @@ _gtk_menu_shell_update_mnemonics (GtkMenuShell *menu_shell)
found = FALSE;
while (target)
{
+ GtkWidget *toplevel = gtk_widget_get_toplevel (GTK_WIDGET (target));
+
/* The idea with keyboard mode is that once you start using
* the keyboard to navigate the menus, we show mnemonics
* until the menu navigation is over. To that end, we spread
@@ -832,14 +834,12 @@ _gtk_menu_shell_update_mnemonics (GtkMenuShell *menu_shell)
*/
if (GTK_IS_MENU_BAR (target))
{
- gtk_window_set_mnemonics_visible (GTK_WINDOW (gtk_widget_get_toplevel (target)),
- FALSE);
+ gtk_window_set_mnemonics_visible (GTK_WINDOW (toplevel), FALSE);
_gtk_label_mnemonics_visible_apply_recursively (GTK_WIDGET (target),
mnemonics_visible);
}
else
- gtk_window_set_mnemonics_visible (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (target))),
- mnemonics_visible);
+ gtk_window_set_mnemonics_visible (GTK_WINDOW (toplevel), mnemonics_visible);
if (target->active_menu_item)
found = TRUE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]