prefs: Queue change notification when app menu visibility changed

Toggling the option should have an immediate effect, not only on
frame/state changes.
This commit is contained in:
Florian Müllner 2014-06-03 00:00:36 +02:00
parent 6af944fe2c
commit d7e99a3f86

View File

@ -1234,6 +1234,7 @@ xsettings_overrides_changed (GSettings *settings,
GVariant *value; GVariant *value;
GVariantDict overrides; GVariantDict overrides;
int shell_shows_app_menu = 1; int shell_shows_app_menu = 1;
gboolean changed = FALSE;
if (!g_settings_get_boolean (settings, "active")) if (!g_settings_get_boolean (settings, "active"))
goto out; goto out;
@ -1247,8 +1248,13 @@ xsettings_overrides_changed (GSettings *settings,
"Gtk/ShellShowsAppMenu", "i", &shell_shows_app_menu); "Gtk/ShellShowsAppMenu", "i", &shell_shows_app_menu);
g_variant_dict_clear (&overrides); g_variant_dict_clear (&overrides);
changed = (show_fallback_app_menu == !!shell_shows_app_menu);
out: out:
show_fallback_app_menu = !shell_shows_app_menu; show_fallback_app_menu = !shell_shows_app_menu;
if (changed)
queue_changed (META_PREF_BUTTON_LAYOUT);
} }
/** /**