]> git.saurik.com Git - wxWidgets.git/commitdiff
don't pass window argument to NotifyCaptureLost, it's not needed/used
authorVáclav Slavík <vslavik@fastmail.fm>
Mon, 31 Jul 2006 12:17:39 +0000 (12:17 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Mon, 31 Jul 2006 12:17:39 +0000 (12:17 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40395 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/window.h
src/common/wincmn.cpp
src/msw/window.cpp

index 338073b554e34e1c693ecb40f2ee19ee5cdf96e9..6efb7a02497e65633ce96223c800d22312df2558 100644 (file)
@@ -1329,9 +1329,8 @@ protected:
     virtual void DoSetWindowVariant( wxWindowVariant variant ) ;
 
     // Must be called when mouse capture is lost to send
-    // wxMouseCaptureLostEvent to windows on capture stack. The argument is
-    // the window gaining capture or NULL if outside of wx code or none.
-    static void NotifyCaptureLost(wxWindow *gainedCapture);
+    // wxMouseCaptureLostEvent to windows on capture stack.
+    static void NotifyCaptureLost();
 
 private:
     // contains the last id generated by NewControlId
index 101c995e7fa33c1d6664810bb088d4882ec9bc4f..62995e54a8acd02bead9e767d983e7a8a0852f16 100644 (file)
@@ -2406,7 +2406,7 @@ static void DoNotifyWindowAboutCaptureLost(wxWindow *win)
 }
 
 /* static */
-void wxWindowBase::NotifyCaptureLost(wxWindow *gainedCapture)
+void wxWindowBase::NotifyCaptureLost()
 {
     // don't do anything if capture lost was expected, i.e. resulted from
     // a wx call to ReleaseMouse or CaptureMouse:
index 2d079a591868df7edab64df68b8668a6b469101d..22b2626855f4ee83d362ab48847bac7f107badbc 100644 (file)
@@ -4107,12 +4107,11 @@ bool wxWindowMSW::HandlePaletteChanged(WXHWND hWndPalChange)
 
 bool wxWindowMSW::HandleCaptureChanged(WXHWND hWndGainedCapture)
 {
-    wxWindow *win = wxFindWinFromHandle(hWndGainedCapture);
-
     // notify windows on the capture stack about lost capture
     // (see http://sourceforge.net/tracker/index.php?func=detail&aid=1153662&group_id=9863&atid=109863):
-    wxWindowBase::NotifyCaptureLost(win);
+    wxWindowBase::NotifyCaptureLost();
 
+    wxWindow *win = wxFindWinFromHandle(hWndGainedCapture);
     wxMouseCaptureChangedEvent event(GetId(), win);
     event.SetEventObject(this);
     return GetEventHandler()->ProcessEvent(event);