[gtk/readonly-events-1: 20/32] x11: Don't generate GDK_DESTROY events



commit f4e1b6496679710999366370a7c82120177d26fd
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Feb 15 11:12:22 2020 -0500

    x11: Don't generate GDK_DESTROY events
    
    GTK does not differentiate between GDK_DESTROY and GDK_DELETE
    anyway.

 gdk/x11/gdkdisplay-x11.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/gdk/x11/gdkdisplay-x11.c b/gdk/x11/gdkdisplay-x11.c
index 7c143b52ff..ea3d80d40f 100644
--- a/gdk/x11/gdkdisplay-x11.c
+++ b/gdk/x11/gdkdisplay-x11.c
@@ -831,7 +831,8 @@ gdk_x11_display_translate_event (GdkEventTranslator *translator,
 
       if (!is_substructure)
        {
-         event->any.type = GDK_DESTROY;
+          /* handle destroy like delete */
+         event->any.type = GDK_DELETE;
          event->any.surface = surface;
 
          return_val = surface && !GDK_SURFACE_DESTROYED (surface);


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