summaryrefslogtreecommitdiff
path: root/src/stack.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@pobox.com>2001-08-19 18:09:10 +0000
committerHavoc Pennington <hp@src.gnome.org>2001-08-19 18:09:10 +0000
commitb2444df787e785895a83ef2fce21a1123f933704 (patch)
treed1f0fe76a014945aca7484e53642d7e18045ed82 /src/stack.c
parentf70993be97dcd7f7a656723185243c323451c1fa (diff)
downloadmetacity-b2444df787e785895a83ef2fce21a1123f933704.tar.gz
metacity-b2444df787e785895a83ef2fce21a1123f933704.tar.bz2
remove XSync, error traps already do that
2001-08-19 Havoc Pennington <hp@pobox.com> * src/display.c (meta_display_grab_window_buttons): remove XSync, error traps already do that (meta_display_grab_window_buttons): implement * src/keybindings.c: src/display.c: wire up the tab window, it rulez!
Diffstat (limited to 'src/stack.c')
-rw-r--r--src/stack.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/stack.c b/src/stack.c
index b7de877..91e7e37 100644
--- a/src/stack.c
+++ b/src/stack.c
@@ -902,6 +902,41 @@ meta_stack_get_tab_next (MetaStack *stack,
return find_tab_forward (stack, NULL, -1);
}
+GSList*
+meta_stack_get_tab_list (MetaStack *stack)
+{
+ GSList *list;
+ int i;
+
+ list = NULL;
+
+ i = 0;
+ while (i < stack->windows->len)
+ {
+ MetaWindow *window;
+ MetaWorkspace *workspace;
+
+ window = meta_display_lookup_x_window (stack->screen->display,
+ GET_XWINDOW (stack, i));
+
+ if (window)
+ workspace = window->screen->active_workspace;
+ else
+ workspace = NULL;
+
+ if (window && IN_TAB_CHAIN (window) &&
+ (workspace == NULL ||
+ meta_workspace_contains_window (workspace, window)))
+ list = g_slist_prepend (list, window);
+
+ ++i;
+ }
+
+ list = g_slist_reverse (list);
+
+ return list;
+}
+
int
meta_stack_windows_cmp (MetaStack *stack,
MetaWindow *window_a,