summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Thurman <tthurman@gnome.org>2009-07-10 08:01:19 -0400
committerThomas Thurman <tthurman@gnome.org>2009-07-10 08:01:19 -0400
commit13576cb982557c1fe286322cb88376dad81b258a (patch)
treed8994fd8f9992ebd1f28c7348a8deac8fdb61d3e
parenta5126ee115af09196e31e35b6b0c894da83a0104 (diff)
downloadmetacity-13576cb982557c1fe286322cb88376dad81b258a.tar.gz
read role from window
-rw-r--r--src/core/matching.c5
-rw-r--r--src/core/matching.h5
-rw-r--r--src/core/window.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/src/core/matching.c b/src/core/matching.c
index 0e79aff3..d781cad3 100644
--- a/src/core/matching.c
+++ b/src/core/matching.c
@@ -42,7 +42,7 @@ load_matching_data (void)
}
void
-meta_matching_load_from_role (MetaWindow *window, gchar *role)
+meta_matching_load_from_role (MetaWindow *window)
{
load_matching_data ();
@@ -50,9 +50,10 @@ meta_matching_load_from_role (MetaWindow *window, gchar *role)
}
void
-meta_matching_save_to_role (MetaWindow *window, gchar *role)
+meta_matching_save_to_role (MetaWindow *window)
{
gint x, y, w, h;
+ gchar *role = window->role;
if (!role)
return;
diff --git a/src/core/matching.h b/src/core/matching.h
index 74bc45d9..f724e76f 100644
--- a/src/core/matching.h
+++ b/src/core/matching.h
@@ -27,10 +27,9 @@
#include "common.h"
#include "window.h"
-/* XXX rename to meta_window_... now the first param is a window */
-void meta_matching_load_from_role (MetaWindow *window, gchar *role);
+void meta_matching_load_from_role (MetaWindow *window);
-void meta_matching_save_to_role (MetaWindow *window, gchar *role);
+void meta_matching_save_to_role (MetaWindow *window);
void meta_matching_save_all (void);
diff --git a/src/core/window.c b/src/core/window.c
index 198085fa..c4a93e95 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -974,7 +974,7 @@ meta_window_free (MetaWindow *window,
meta_verbose ("Unmanaging 0x%lx\n", window->xwindow);
- meta_matching_save_to_role (window, "dummy2");
+ meta_matching_save_to_role (window);
if (window->display->compositor)
meta_compositor_free_window (window->display->compositor, window);