Process capture lost event to avoid assertion

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44073 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart 2006-12-29 19:37:04 +00:00
parent 046c2f1404
commit 61f84e2493
2 changed files with 7 additions and 0 deletions

View File

@ -600,6 +600,7 @@ public:
void Command(wxCommandEvent& event);
void OnDropFiles(wxDropFilesEvent& event);
void OnCaptureLost(wxMouseCaptureLostEvent& event);
void OnCut(wxCommandEvent& event);
void OnCopy(wxCommandEvent& event);

View File

@ -74,6 +74,7 @@ BEGIN_EVENT_TABLE( wxRichTextCtrl, wxControl )
EVT_SIZE(wxRichTextCtrl::OnSize)
EVT_SET_FOCUS(wxRichTextCtrl::OnSetFocus)
EVT_KILL_FOCUS(wxRichTextCtrl::OnKillFocus)
EVT_MOUSE_CAPTURE_LOST(wxRichTextCtrl::OnCaptureLost)
EVT_CONTEXT_MENU(wxRichTextCtrl::OnContextMenu)
EVT_MENU(wxID_UNDO, wxRichTextCtrl::OnUndo)
@ -325,6 +326,11 @@ void wxRichTextCtrl::OnKillFocus(wxFocusEvent& WXUNUSED(event))
// Refresh(false);
}
void wxRichTextCtrl::OnCaptureLost(wxMouseCaptureLostEvent& WXUNUSED(event))
{
m_dragging = false;
}
/// Left-click
void wxRichTextCtrl::OnLeftClick(wxMouseEvent& event)
{