20#ifndef RESETTABLE_PANEL_H_
21#define RESETTABLE_PANEL_H_
28#define wxRESETTABLE 0x00008000
29#define ID_RESET_PANEL ID_PREFERENCES_RESET_PANEL
38 const wxPoint& aPos = wxDefaultPosition,
39 const wxSize& aSize = wxSize( -1,-1 ),
40 long aStyle = wxTAB_TRAVERSAL,
41 const wxString& aName = wxEmptyString )
42 : wxPanel( aParent, aId, aPos, aSize, aStyle |
wxRESETTABLE, aName )
44 Bind( wxEVT_COMMAND_BUTTON_CLICKED,
45 [&]( wxCommandEvent& aCmd )
66 return _(
"Reset all settings on this page to their default" );
74 if( aPt == wxPoint( -INT_MAX, INT_MAX ) )
77 return wxPanel::GetHelpTextAtPoint( aPt, aOrigin );
A wxPanel that is designed to be reset in a standard manner.
RESETTABLE_PANEL(wxWindow *aParent, wxWindowID aId=wxID_ANY, const wxPoint &aPos=wxDefaultPosition, const wxSize &aSize=wxSize(-1,-1), long aStyle=wxTAB_TRAVERSAL, const wxString &aName=wxEmptyString)
virtual void ResetPanel()=0
Reset the contents of this panel.
virtual wxString GetResetTooltip() const
Get the tooltip the reset button should display when showing this panel.
wxString GetHelpTextAtPoint(const wxPoint &aPt, wxHelpEvent::Origin aOrigin) const override
Overridden to supply the reset button tooltip when queried with { -INT_MAX, INT_MAX }.