wxWindow::OnClose() removed completely from wxGTK, wxCloseEvent is now
processed properly. Also, fixes for compilation without WXWIN_COMPATIBILITY on. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1608 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1716,9 +1716,15 @@ bool wxWindow::Close( bool force )
|
||||
|
||||
wxCloseEvent event(wxEVT_CLOSE_WINDOW, m_windowId);
|
||||
event.SetEventObject(this);
|
||||
event.SetForce(force);
|
||||
event.SetCanVeto(!force);
|
||||
|
||||
return GetEventHandler()->ProcessEvent(event);
|
||||
(void)GetEventHandler()->ProcessEvent(event);
|
||||
|
||||
// when we're forced to close we do it anyhow, otherwise only if the
|
||||
// application didn't forbid it (if the event wasn't processed, GetVeto()
|
||||
// will return FALSE too)
|
||||
if ( force || !event.GetVeto() )
|
||||
Destroy();
|
||||
}
|
||||
|
||||
bool wxWindow::Destroy()
|
||||
@@ -2235,11 +2241,6 @@ bool wxWindow::AcceptsFocus() const
|
||||
return IsEnabled() && IsShown() && m_acceptsFocus;
|
||||
}
|
||||
|
||||
bool wxWindow::OnClose()
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void wxWindow::AddChild( wxWindow *child )
|
||||
{
|
||||
wxCHECK_RET( (m_widget != NULL), "invalid window" );
|
||||
|
Reference in New Issue
Block a user