// selecting?
if ( event.LeftIsDown() )
{
- wxASSERT_MSG( m_Selecting, "should be set in OnMouseLeftDown" );
-
- m_llist->ContinueSelection(cursorPos, m_ClickPosition);
- DoPaint(); // TODO: we don't have to redraw everything!
+ // m_Selecting might not be set if the button got pressed
+ // outside this window, so check for it:
+ if(m_Selecting)
+ {
+ m_llist->ContinueSelection(cursorPos, m_ClickPosition);
+ DoPaint(); // TODO: we don't have to redraw everything!
+ }
}
if ( u )