|
OpenCPN Partial API docs
|
Input dialog with panel and flex grid sizer. More...
#include <dialog_input.h>
Public Member Functions | |
| InputDialog (wxWindow *parent, const std::string &title, const std::string &action=_("Continue").ToStdString()) | |
| SwitchField * | AddSelection (int key, const std::string &label, bool value) |
| Add key selection switch. | |
| template<typename T > | |
| void | AddSelection (const std::set< int > &options, T option, const std::string &label) |
| Create selection switch for options. | |
| void | GetSelected (std::set< int > &options) |
| Return active switch keys. | |
Public Member Functions inherited from AlertDialog | |
| AlertDialog (wxWindow *parent, const std::string &title) | |
| Alert dialog with close button. | |
| AlertDialog (wxWindow *parent, const std::string &title, const std::string &action) | |
| Alert dialog with labelled confirmation button and cancel. | |
| void | SetListener (IAlertConfirmation *listener) |
| Listen for response. | |
| void | SetTimer (int seconds) |
| Activate timer. | |
| void | SetMessage (const std::string &msg) |
| Set alert message. | |
| void | SetDefaultButton (int id) |
| Set default button (for enter). | |
| void | SetCancelLabel (const std::string &label) |
| Overwrite cancel button label. | |
| int | ShowModal () override |
| Show dialog and return response. | |
Public Member Functions inherited from BaseDialog | |
| BaseDialog (wxWindow *parent, const std::string &title, long style=wxDEFAULT_DIALOG_STYLE) | |
| void | SetInitialSize () |
| Initialize by display geometry. | |
| void | AddHtmlContent (const std::stringstream &html) |
| Display HTML content with dark support. | |
Additional Inherited Members | |
Static Public Member Functions inherited from AlertDialog | |
| static int | GetConfirmation (wxWindow *parent, const std::string &title, const std::string &action, const std::string &msg) |
| Helper that returns the dialog response. | |
Protected Attributes inherited from BaseDialog | |
| wxBoxSizer * | m_layout |
| wxBoxSizer * | m_content |
Static Protected Attributes inherited from BaseDialog | |
| static const int | kDialogPadding = 2 |
Input dialog with panel and flex grid sizer.
Definition at line 33 of file dialog_input.h.
|
inline |
Create selection switch for options.
The option value is true if the option is in the set, or when the set is empty.
| options | Default or saved options. |
| option | An enum class key (to be cast to int). |
| label | Label for the option. |
Definition at line 56 of file dialog_input.h.
| SwitchField * InputDialog::AddSelection | ( | int | key, |
| const std::string & | label, | ||
| bool | value | ||
| ) |
Add key selection switch.
| key | Key identifier. |
| label | Selection label. |
| value | Default value. |
| void InputDialog::GetSelected | ( | std::set< int > & | options | ) |
Return active switch keys.
| options | Set of selected keys. |