[gtk+] window: Don't send startup notifications for offscreen / popup windows



commit 04e727709d562d7a86a115723d0356592ab06333
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Mon Jun 29 14:16:49 2015 -0700

    window: Don't send startup notifications for offscreen / popup windows
    
    The WM isn't aware of O-R (popup) or offscreen windows. If somebody
    maps an offscreen or a popup GTK+ window before the main window, we'll
    complete the sequence before a "real" window is mapped. Make sure to
    ignore these for startup notifies.

 gtk/gtkwindow.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index ce24667..add6b79 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -6129,7 +6129,9 @@ gtk_window_map (GtkWidget *widget)
 
   gdk_window_show (gdk_window);
 
-  if (!disable_startup_notification)
+  if (!disable_startup_notification &&
+      !GTK_IS_OFFSCREEN_WINDOW (window) &&
+      priv->type != GTK_WINDOW_POPUP)
     {
       /* Do we have a custom startup-notification id? */
       if (priv->startup_id != NULL)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]