--- metacity-2.9.0/src/window.c	2004-10-25 18:24:01.000000000 +0200
+++ metacity-2.9.0-mod2/src/window.c	2004-11-24 21:11:21.000000000 +0100
@@ -1229,6 +1229,44 @@
   return is_minimized;
 }
 
+/* Check whether all other normal group windows are minimized */
+static gboolean
+group_is_minimized (MetaWindow *window)
+{
+  MetaGroup *group;
+  GSList *group_windows;
+  GSList *tmp;
+
+  group = meta_window_get_group (window);
+  if (group)
+    group_windows = meta_group_list_windows (group);
+  else
+    group_windows = NULL;
+
+  tmp = group_windows;
+  while (tmp)
+    {
+      MetaWindow *w;
+
+      w = tmp->data;
+
+      if (w->type == META_WINDOW_NORMAL &&
+          (w->stack_position > 0 ||
+           window->screen == w->screen) &&
+          window->xwindow != w->xwindow &&
+          !w->minimized)
+        {
+          g_slist_free (group_windows);
+          return FALSE;
+        }
+
+      tmp = tmp->next;
+    }
+
+  g_slist_free (group_windows);
+  return TRUE;
+}
+
 static gboolean
 window_showing_on_its_workspace (MetaWindow *window)
 {
@@ -1284,8 +1322,12 @@
   
   if (showing)
     {
-      if (ancestor_is_minimized (window))
-        showing = FALSE;
+      if (ancestor_is_minimized (window) ||
+          (window->type == META_WINDOW_UTILITY &&
+           group_is_minimized (window)))
+        {
+          showing = FALSE;
+        }
     }
 
 #if 0
@@ -1446,7 +1488,6 @@
       MetaWindow *window;
 
       window = tmp->data;
-
       if (!window->placed)
         unplaced = g_slist_prepend (unplaced, window);
       else if (window_should_be_showing (window))
@@ -1907,10 +1948,10 @@
       window->minimized = TRUE;
       meta_window_queue_calc_showing (window);
 
-      meta_window_foreach_transient (window,
+      meta_window_foreach_group (window,
                                      queue_calc_showing_func,
                                      NULL);
-      
+
       if (window->has_focus)
         {
           meta_topic (META_DEBUG_FOCUS,
@@ -1935,7 +1976,7 @@
       window->minimized = FALSE;
       meta_window_queue_calc_showing (window);
 
-      meta_window_foreach_transient (window,
+      meta_window_foreach_group (window,
                                      queue_calc_showing_func,
                                      NULL);
     }
@@ -6914,6 +6955,41 @@
 }
 
 void
+meta_window_foreach_group (MetaWindow            *window,
+                           MetaWindowForeachFunc  func,
+                           void                  *data)
+{
+  MetaGroup *group;
+  GSList *group_windows;
+  GSList *tmp;
+
+  group = meta_window_get_group (window);
+  if (group != NULL)
+    group_windows = meta_group_list_windows (group);
+  else
+    group_windows = NULL;
+
+  tmp = group_windows;
+  while (tmp)
+    {
+      MetaWindow *group_window = tmp->data;
+
+      if (group_window->stack_position <= 0 ||
+          window->screen != group_window->screen ||
+          window->xwindow == group_window->xwindow)
+        {
+          tmp = tmp->next;
+          continue;
+        }
+
+      meta_window_queue_calc_showing (group_window);
+
+      tmp = tmp->next;
+    }
+  g_slist_free (group_windows);
+}
+
+void
 meta_window_foreach_ancestor (MetaWindow            *window,
                               MetaWindowForeachFunc  func,
                               void                  *data)
--- metacity-2.9.0/src/window.h	2004-10-13 20:51:33.000000000 +0200
+++ metacity-2.9.0-mod2/src/window.h	2004-11-24 20:53:03.000000000 +0100
@@ -495,6 +495,9 @@
 void     meta_window_foreach_transient        (MetaWindow            *window,
                                                MetaWindowForeachFunc  func,
                                                void                  *data);
+void     meta_window_foreach_group            (MetaWindow            *window,
+                                               MetaWindowForeachFunc  func,
+                                               void                  *data);
 gboolean meta_window_is_ancestor_of_transient (MetaWindow            *window,
                                                MetaWindow            *transient);
 void     meta_window_foreach_ancestor         (MetaWindow            *window,
