2009-02-02 Carlos Alberto Cortez <calberto.cortez@gmail.com>
authorCarlos Alberto Cortez <calberto.cortez@gmail.com>
Mon, 2 Feb 2009 09:28:08 +0000 (09:28 -0000)
committerCarlos Alberto Cortez <calberto.cortez@gmail.com>
Mon, 2 Feb 2009 09:28:08 +0000 (09:28 -0000)
* XplatUIX11.cs: Don't send a WM_SHOWWINDOW message when receiving
MapNotify/UnmapNotify events - we are already firing those events in
the proper places, so we avoid this way to send the same message two
times. I'm leaving the handling code in case we could break something
in the future, as this change seems dangerous (but needed).
Fixes #467546.

svn path=/trunk/mcs/; revision=125325

mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIX11.cs

index b55fa429d037f9e1766a61964be66c14fa0a0bc7..980a55f40aa053feb9209fc8b37836a2eea267a5 100644 (file)
@@ -1,3 +1,12 @@
+2009-02-02  Carlos Alberto Cortez <calberto.cortez@gmail.com>
+
+       * XplatUIX11.cs: Don't send a WM_SHOWWINDOW message when receiving
+       MapNotify/UnmapNotify events - we are already firing those events in
+       the proper places, so we avoid this way to send the same message two
+       times. I'm leaving the handling code in case we could break something
+       in the future, as this change seems dangerous (but needed).
+       Fixes #467546.
+
 2009-02-01  Ivan N. Zlatev  <contact@i-nz.net>
 
        * DataGridView.cs: Complete incomplete rows when they are added to 
index 22335bc741e077b7d220ac83bafc276182fd79ad..4ebf4a8c55cc76604d84f15608c5c6dfc6535ab2 100644 (file)
@@ -4367,25 +4367,27 @@ namespace System.Windows.Forms {
                                        goto ProcessNextMessage;
                                }
 
+                               // We are already firing WM_SHOWWINDOW messages in the proper places, but I'm leaving this code
+                               // in case we break a scenario not taken into account in the tests
                                case XEventName.MapNotify: {
-                                       if (client && (xevent.ConfigureEvent.xevent == xevent.ConfigureEvent.window)) { // Ignore events for children (SubstructureNotify) and client areas
+                                       /*if (client && (xevent.ConfigureEvent.xevent == xevent.ConfigureEvent.window)) {       // Ignore events for children (SubstructureNotify) and client areas
                                                hwnd.mapped = true;
                                                msg.message = Msg.WM_SHOWWINDOW;
                                                msg.wParam = (IntPtr) 1;
                                                // XXX we're missing the lParam..
                                                break;
-                                       }
+                                       }*/
                                        goto ProcessNextMessage;
                                }
 
                                case XEventName.UnmapNotify: {
-                                       if (client && (xevent.ConfigureEvent.xevent == xevent.ConfigureEvent.window)) { // Ignore events for children (SubstructureNotify) and client areas
+                                       /*if (client && (xevent.ConfigureEvent.xevent == xevent.ConfigureEvent.window)) {       // Ignore events for children (SubstructureNotify) and client areas
                                                hwnd.mapped = false;
                                                msg.message = Msg.WM_SHOWWINDOW;
                                                msg.wParam = (IntPtr) 0;
                                                // XXX we're missing the lParam..
                                                break;
-                                       }
+                                       }*/
                                        goto ProcessNextMessage;
                                }