Improve mouse handling code in wxAuiToolBar.
Capture the mouse to handle mouse input on the buttons to ensure we always reset the button when the mouse leaves it. Closes #11784. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65669 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -616,6 +616,7 @@ protected: // handlers
|
||||
void OnMiddleUp(wxMouseEvent& evt);
|
||||
void OnMotion(wxMouseEvent& evt);
|
||||
void OnLeaveWindow(wxMouseEvent& evt);
|
||||
void OnCaptureLost(wxMouseCaptureLostEvent& evt);
|
||||
void OnSetCursor(wxSetCursorEvent& evt);
|
||||
|
||||
protected:
|
||||
@@ -657,6 +658,10 @@ protected:
|
||||
wxSize m_horzHintSize;
|
||||
wxSize m_vertHintSize;
|
||||
|
||||
private:
|
||||
// Common part of OnLeaveWindow() and OnCaptureLost().
|
||||
void DoResetMouseState();
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
DECLARE_CLASS(wxAuiToolBar)
|
||||
};
|
||||
|
Reference in New Issue
Block a user