]> git.saurik.com Git - wxWidgets.git/blobdiff - src/os2/window.cpp
Compilation fix.
[wxWidgets.git] / src / os2 / window.cpp
index 8553ee68e20c835d41726db852bcd1ed2cfa013b..7903c10e6c5bf4e28758a0f84e6258c8925cde0a 100644 (file)
@@ -1364,7 +1364,8 @@ void wxWindowOS2::OnIdle(
             (void)GetEventHandler()->ProcessEvent(rEvent);
         }
     }
-    UpdateWindowUI();
+    if (wxUpdateUIEvent::CanUpdate())
+        UpdateWindowUI();
 } // end of wxWindowOS2::OnIdle
 
 //
@@ -1454,14 +1455,7 @@ void wxWindowOS2::SetDropTarget(
   wxDropTarget*                     pDropTarget
 )
 {
-    if (m_dropTarget != 0)
-    {
-        m_dropTarget->Revoke(m_hWnd);
-        delete m_dropTarget;
-    }
     m_dropTarget = pDropTarget;
-    if (m_dropTarget != 0)
-        m_dropTarget->Register(m_hWnd);
 } // end of wxWindowOS2::SetDropTarget
 #endif
 
@@ -3521,7 +3515,7 @@ bool wxWindowOS2::HandleCreate(
 bool wxWindowOS2::HandleDestroy()
 {
     wxWindowDestroyEvent            vEvent((wxWindow*)this);
-
+    vEvent.SetId(GetId());
     (void)GetEventHandler()->ProcessEvent(vEvent);
 
     //
@@ -3530,7 +3524,6 @@ bool wxWindowOS2::HandleDestroy()
 #if wxUSE_DRAG_AND_DROP
     if (m_dropTarget != NULL)
     {
-        m_dropTarget->Revoke(m_hWnd);
         delete m_dropTarget;
         m_dropTarget = NULL;
     }