#include <wxOptions.h>


Public Member Functions | |
| wxBoolOption (const wxString &configValueName, const wxString &description, bool defaultValue, boolStorage storeInverted=boolStoreNormal, bool enableIfChecked=true) | |
| wxBoolOption * | Add (wxOption *option) |
| void | OnCheck (wxCommandEvent &event) |
| ~wxBoolOption () | |
| void | DoDisplay (wxOptionSizer *sizer, wxWindow *parent) |
| you should override the following functions: | |
| void | OnWindowDestroy () |
| When this is called, then you should save out any values stored in controls, as they will be destroyed soon. | |
| bool | DoSave () |
| Save any values to the config that needs to be saved. | |
| bool | Enable (bool enable) |
| Enable/disable any controls that need to be enabled/disabled. | |
| void | SetParent (wxOptionGroup *parent) |
| This is only here so that some options can create subgroups of the current wxOptionGroup. | |
Private Member Functions | |
| bool | ChildEnabled (bool enable) |
Private Attributes | |
| bool | m_enableIfChecked |
| bool | m_defaultValue |
| boolStorage | m_storeInverted |
| wxCheckBox * | m_checkBox |
| Options | m_options |
Can also control a group of related options.
Definition at line 246 of file wxOptions.h.
| wxBoolOption::wxBoolOption | ( | const wxString & | configValueName, | |
| const wxString & | description, | |||
| bool | defaultValue, | |||
| boolStorage | storeInverted = boolStoreNormal, |
|||
| bool | enableIfChecked = true | |||
| ) | [inline] |
Definition at line 248 of file wxOptions.h.
| wxBoolOption::~wxBoolOption | ( | ) |
Definition at line 128 of file wxOptions.cpp.
| wxBoolOption * wxBoolOption::Add | ( | wxOption * | option | ) |
Definition at line 47 of file wxOptions.cpp.
| void wxBoolOption::OnCheck | ( | wxCommandEvent & | event | ) |
Definition at line 78 of file wxOptions.cpp.
| void wxBoolOption::DoDisplay | ( | wxOptionSizer * | sizer, | |
| wxWindow * | parent | |||
| ) | [virtual] |
you should override the following functions:
This is called when the option is going to be displayed. You should add your controls to a sizer, and then wait for OnWindowDestroy() to be called. If you need to get the value of a control (ie, a textbox), then you should keep pointers to them around. However, do not delete the controls, since they are owned by the parent dialog and will be automatically deleted.
| sizer | is a wxOptionSizer that has two columns that your controls should be added to | |
| parent | is a reference to the parent window that you should pass to your child controls. |
Implements wxOption.
Definition at line 53 of file wxOptions.cpp.
| void wxBoolOption::OnWindowDestroy | ( | ) | [virtual] |
When this is called, then you should save out any values stored in controls, as they will be destroyed soon.
Implements wxOption.
Definition at line 88 of file wxOptions.cpp.
| bool wxBoolOption::DoSave | ( | ) | [virtual] |
Save any values to the config that needs to be saved.
Please note that this will _not_ always be called. It is only called if DoDisplay() was called for your option
Implements wxOption.
Definition at line 97 of file wxOptions.cpp.
| bool wxBoolOption::Enable | ( | bool | enable | ) | [virtual] |
Enable/disable any controls that need to be enabled/disabled.
Don't bother doing this with static labels, that just seems like it would be annoying and useless.
Implements wxOption.
Definition at line 108 of file wxOptions.cpp.
| void wxBoolOption::SetParent | ( | wxOptionGroup * | parent | ) | [virtual] |
This is only here so that some options can create subgroups of the current wxOptionGroup.
.. its a huge hack, see buttonOption for more information
Reimplemented from wxOption.
Definition at line 119 of file wxOptions.cpp.
| bool wxBoolOption::ChildEnabled | ( | bool | enable | ) | [private] |
Definition at line 137 of file wxOptions.cpp.
bool wxBoolOption::m_enableIfChecked [private] |
Definition at line 271 of file wxOptions.h.
bool wxBoolOption::m_defaultValue [private] |
Definition at line 272 of file wxOptions.h.
boolStorage wxBoolOption::m_storeInverted [private] |
Definition at line 273 of file wxOptions.h.
wxCheckBox* wxBoolOption::m_checkBox [private] |
Definition at line 275 of file wxOptions.h.
Options wxBoolOption::m_options [private] |
Definition at line 276 of file wxOptions.h.
1.5.5