diff options
author | Matthias Clasen <mclasen@fedoraproject.org> | 2009-03-12 02:55:30 +0000 |
---|---|---|
committer | Matthias Clasen <mclasen@fedoraproject.org> | 2009-03-12 02:55:30 +0000 |
commit | 20cf74d5ead6c26570d8cebe922a6b1fbde08753 (patch) | |
tree | 7fcda053cc880faa6c2670410f32df824d691d1e /metacity-struts.patch | |
parent | cf075a625b9983891a4f631337e383f1b3375893 (diff) | |
download | metacity-20cf74d5ead6c26570d8cebe922a6b1fbde08753.tar.gz metacity-20cf74d5ead6c26570d8cebe922a6b1fbde08753.tar.xz metacity-20cf74d5ead6c26570d8cebe922a6b1fbde08753.zip |
fix autohide panel interactionmetacity-2_25_144-6_fc11
Diffstat (limited to 'metacity-struts.patch')
-rw-r--r-- | metacity-struts.patch | 109 |
1 files changed, 109 insertions, 0 deletions
diff --git a/metacity-struts.patch b/metacity-struts.patch new file mode 100644 index 0000000..1ec08cb --- /dev/null +++ b/metacity-struts.patch @@ -0,0 +1,109 @@ +--- trunk/src/core/window-props.c 2009/03/11 14:21:33 4190 ++++ trunk/src/core/window-props.c 2009/03/12 01:09:41 4191 +@@ -73,12 +73,6 @@ + ReloadValueFunc reload_func; + } MetaWindowPropHooks; + +-static void init_prop_value (MetaDisplay *display, +- Atom property, +- MetaPropValue *value); +-static void reload_prop_value (MetaWindow *window, +- MetaPropValue *value, +- gboolean initial); + static MetaWindowPropHooks* find_hooks (MetaDisplay *display, + Atom property); + +@@ -128,23 +122,34 @@ + g_return_if_fail (n_properties > 0); + + values = g_new0 (MetaPropValue, n_properties); +- +- i = 0; +- while (i < n_properties) ++ ++ for (i=0; i<n_properties; i++) + { +- init_prop_value (window->display, properties[i], &values[i]); +- ++i; ++ MetaWindowPropHooks *hooks = find_hooks (window->display, ++ properties[i]); ++ ++ if (!hooks || hooks->type == META_PROP_VALUE_INVALID) ++ { ++ values[i].type = META_PROP_VALUE_INVALID; ++ values[i].atom = None; ++ } ++ else ++ { ++ values[i].type = hooks->type; ++ values[i].atom = properties[i]; ++ } + } + + meta_prop_get_values (window->display, xwindow, + values, n_properties); + +- i = 0; +- while (i < n_properties) ++ for (i=0; i<n_properties; i++) + { +- reload_prop_value (window, &values[i], initial); +- +- ++i; ++ MetaWindowPropHooks *hooks = find_hooks (window->display, ++ properties[i]); ++ ++ if (hooks && hooks->reload_func != NULL) ++ (* hooks->reload_func) (window, &values[i], initial); + } + + meta_prop_free_values (values, n_properties); +@@ -152,37 +157,6 @@ + g_free (values); + } + +-/* Fill in the MetaPropValue used to get the value of "property" */ +-static void +-init_prop_value (MetaDisplay *display, +- Atom property, +- MetaPropValue *value) +-{ +- MetaWindowPropHooks *hooks = find_hooks (display, property); +- +- if (!hooks || hooks->type == META_PROP_VALUE_INVALID) +- { +- value->type = META_PROP_VALUE_INVALID; +- value->atom = None; +- } +- else +- { +- value->type = hooks->type; +- value->atom = property; +- } +-} +- +-static void +-reload_prop_value (MetaWindow *window, +- MetaPropValue *value, +- gboolean initial) +-{ +- MetaWindowPropHooks *hooks = find_hooks (window->display, value->atom); +- +- if (hooks && hooks->reload_func != NULL) +- (* hooks->reload_func) (window, value, initial); +-} +- + static void + reload_wm_client_machine (MetaWindow *window, + MetaPropValue *value, +@@ -1566,6 +1540,9 @@ + display->prop_hooks_table = NULL; + } + ++/** ++ * Finds the hooks for a particular property. ++ */ + static MetaWindowPropHooks* + find_hooks (MetaDisplay *display, + Atom property) + |