Index: src/window.c
===================================================================
RCS file: /cvs/gnome/metacity/src/window.c,v
retrieving revision 1.341
diff -p -u -r1.341 window.c
--- src/window.c	19 Aug 2004 02:05:24 -0000	1.341
+++ src/window.c	27 Aug 2004 04:12:25 -0000
@@ -7298,9 +7298,9 @@ meta_window_stack_just_below (MetaWindow
       meta_topic (META_DEBUG_STACK,
                   "Setting stack position of window %s to %d (making it below window %s).\n",
                   window->desc, 
-                  below_this_one->stack_position - 1, 
+                  below_this_one->stack_position, 
                   below_this_one->desc);
-      meta_window_set_stack_position (window, below_this_one->stack_position - 1);
+      meta_window_set_stack_position (window, below_this_one->stack_position);
     }
   else
     {
Index: src/workspace.c
===================================================================
RCS file: /cvs/gnome/metacity/src/workspace.c,v
retrieving revision 1.59
diff -p -u -r1.59 workspace.c
--- src/workspace.c	6 Aug 2004 18:13:55 -0000	1.59
+++ src/workspace.c	27 Aug 2004 04:12:26 -0000
@@ -31,6 +31,15 @@ void meta_workspace_queue_calc_showing  
 
 static void set_active_space_hint      (MetaScreen *screen);
 
+static void
+maybe_add_to_list (MetaScreen *screen, MetaWindow *window, gpointer data)
+{
+  GList **mru_list = data;
+
+  if (window->on_all_workspaces)
+    *mru_list = g_list_prepend (*mru_list, window);
+}
+
 MetaWorkspace*
 meta_workspace_new (MetaScreen *screen)
 {
@@ -43,6 +52,7 @@ meta_workspace_new (MetaScreen *screen)
     g_list_append (workspace->screen->workspaces, workspace);
   workspace->windows = NULL;
   workspace->mru_list = NULL;
+  meta_screen_foreach_window (screen, maybe_add_to_list, &workspace->mru_list);
 
   workspace->work_areas = NULL;
   workspace->work_areas_invalid = TRUE;
