Add wxHtmlHelpController::SetShouldPreventAppExit().
Add a method which can be used to indicate that the help window should prevent the application from exiting and use it in the help sample to prevent it from closing prematurely. Closes #13046. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67228 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -115,9 +115,11 @@ public:
|
||||
// Override to add custom buttons to the toolbar
|
||||
virtual void AddToolbarButtons(wxToolBar* WXUNUSED(toolBar), int WXUNUSED(style)) {}
|
||||
|
||||
void SetShouldPreventAppExit(bool enable);
|
||||
|
||||
// we don't want to prevent the app from closing just because a help window
|
||||
// remains opened
|
||||
virtual bool ShouldPreventAppExit() const { return false; }
|
||||
virtual bool ShouldPreventAppExit() const { return m_shouldPreventAppExit; }
|
||||
|
||||
protected:
|
||||
void Init(wxHtmlHelpData* data = NULL);
|
||||
@@ -143,6 +145,7 @@ protected:
|
||||
wxString m_TitleFormat; // title of the help frame
|
||||
wxHtmlHelpWindow *m_HtmlHelpWin;
|
||||
wxHtmlHelpController* m_helpController;
|
||||
bool m_shouldPreventAppExit;
|
||||
|
||||
private:
|
||||
|
||||
|
Reference in New Issue
Block a user