git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56221
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
- <property name="style"></property>
+ <property name="style">wxRB_GROUP</property>
<property name="subclass"></property>
<property name="tooltip">wxRadioButton</property>
<property name="value">1</property>
<property name="subclass"></property>
<property name="tooltip">wxRadioButton</property>
<property name="value">1</property>
fgSizer1->Add( m_checkBox2, 0, wxALL|wxALIGN_CENTER_VERTICAL|wxALIGN_CENTER_HORIZONTAL, 20 );
fgSizer1->Add( m_checkBox2, 0, wxALL|wxALIGN_CENTER_VERTICAL|wxALIGN_CENTER_HORIZONTAL, 20 );
- m_radioBtn1 = new wxRadioButton( m_panel1, wxID_ANY, _("Checked"), wxDefaultPosition, wxDefaultSize, 0 );
+ m_radioBtn1 = new wxRadioButton( m_panel1, wxID_ANY, _("Checked"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP );
m_radioBtn1->SetValue( true );
m_radioBtn1->SetToolTip( _("wxRadioButton") );
m_radioBtn1->SetValue( true );
m_radioBtn1->SetToolTip( _("wxRadioButton") );
e.g. you cannot load a richtext file in a wxRichtextCtrl during initialization.
Those customizations will be done here.
e.g. you cannot load a richtext file in a wxRichtextCtrl during initialization.
Those customizations will be done here.
+
+
+ NB: under wxGTK for the radio button "unchecked" to be unchecked, it's
+ important to put the wxRB_GROUP style on the first wxRadioButton
+ (the one "checked") and no flags on the second one.
*/
void ScreenshotFrame::InitFBControls()
{
*/
void ScreenshotFrame::InitFBControls()
{
- // explicitely uncheck radio button:
- m_radioBtn2->SetValue(false);
-
// For some reason, wxFormBuilder does not set the scrollbar range
m_scrollBar1->SetScrollbar(50, 1, 100, 1);
// For some reason, wxFormBuilder does not set the scrollbar range
m_scrollBar1->SetScrollbar(50, 1, 100, 1);