83d0cb4
diff -Nur xfwm4-4.6.1.orig/src/focus.c xfwm4-4.6.1/src/focus.c
83d0cb4
--- xfwm4-4.6.1.orig/src/focus.c	2009-04-15 01:58:59.000000000 -0600
83d0cb4
+++ xfwm4-4.6.1/src/focus.c	2009-07-28 19:31:44.000000000 -0600
83d0cb4
@@ -214,7 +214,12 @@
83d0cb4
     {
83d0cb4
         Client *c2 = clientGetFocus();
83d0cb4
 
83d0cb4
-        if ((c2 != NULL) && (c2->win_layer == c->win_layer))
83d0cb4
+        /*
83d0cb4
+         * Place windows under the currently focused only if focus
83d0cb4
+         * stealing prevention had prevented the focus transition,
83d0cb4
+         * otherwise, leave the unfocused window on top.
83d0cb4
+         */
83d0cb4
+        if ((c2 != NULL) && (c2->win_layer == c->win_layer) && prevented)
83d0cb4
         {
83d0cb4
             clientSortRing(c);
83d0cb4
             clientLower (c, c2->frame);