]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mgl/window.cpp
added a preImage of the selection in order to avoid unnecessary events being triggered
[wxWidgets.git] / src / mgl / window.cpp
index 3f98b46db10feafcc3834dc5b433d0984cf7c569..830b19167d6990126a95893ed3f4fc350bc2c8bf 100644 (file)
@@ -929,11 +929,15 @@ void wxWindowMGL::DoSetSize(int x, int y, int width, int height, int sizeFlags)
         }
     }
 
-    DoMoveWindow(x, y, width, height);
+    if ( m_wnd->x != x || m_wnd->y != y || 
+         (int)m_wnd->width != width || (int)m_wnd->height != height )
+    {
+        DoMoveWindow(x, y, width, height);
 
-    wxSizeEvent event(wxSize(width, height), GetId());
-    event.SetEventObject(this);
-    GetEventHandler()->ProcessEvent(event);
+        wxSizeEvent event(wxSize(width, height), GetId());
+        event.SetEventObject(this);
+        GetEventHandler()->ProcessEvent(event);
+    }
 }
 
 void wxWindowMGL::DoSetClientSize(int width, int height)