send END_EDIT label if label editing is cancelled

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@24111 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2003-10-07 08:41:54 +00:00
parent 9692f42bc6
commit d2ed74b912
5 changed files with 127 additions and 103 deletions

View File

@@ -2834,25 +2834,12 @@ bool wxListMainWindow::OnRenameAccept(size_t itemEdit, const wxString& value)
le.IsAllowed();
}
#ifdef __VMS__ // Ignore unreacheable code
# pragma message disable initnotreach
#endif
void wxListMainWindow::OnRenameCancelled(size_t WXUNUSED(itemEdit))
{
// wxMSW seems not to notify the program about
// cancelled label edits.
return;
#if 0
// above unconditional return cause warning about not reachable code
// let owner know that the edit was cancelled
wxListEvent le( wxEVT_COMMAND_LIST_END_LABEL_EDIT, GetParent()->GetId() );
// These only exist for wxTreeCtrl, which should probably be changed
// le.m_editCancelled = TRUE;
// le.m_label = wxEmptyString;
le.SetEditCanceled(TRUE);
le.SetEventObject( GetParent() );
le.m_itemIndex = itemEdit;
@@ -2863,11 +2850,7 @@ void wxListMainWindow::OnRenameCancelled(size_t WXUNUSED(itemEdit))
data->GetItem( 0, le.m_item );
GetEventHandler()->ProcessEvent( le );
#endif
}
#ifdef __VMS__
# pragma message enable initnotreach
#endif
void wxListMainWindow::OnMouse( wxMouseEvent &event )
{