21 #include "radiobutton.moc"
25 : TQRadioButton(parent, name),
26 mFocusPolicy(focusPolicy()),
32 : TQRadioButton(text, parent, name),
33 mFocusPolicy(focusPolicy()),
44 if ((
int)ro != (
int)mReadOnly)
47 setFocusPolicy(ro ? TQWidget::NoFocus : mFocusPolicy);
59 mFocusWidgetEnable = enable;
61 connect(
this, TQ_SIGNAL(clicked()), TQ_SLOT(slotClicked()));
63 disconnect(
this, TQ_SIGNAL(clicked()),
this, TQ_SLOT(slotClicked()));
70 void RadioButton::slotClicked()
72 if (mFocusWidget && isChecked())
74 if (mFocusWidgetEnable)
75 mFocusWidget->setEnabled(
true);
76 mFocusWidget->setFocus();
84 void RadioButton::mousePressEvent(TQMouseEvent* e)
89 if (e->button() == TQt::LeftButton)
92 TQRadioButton::mousePressEvent(e);
95 void RadioButton::mouseReleaseEvent(TQMouseEvent* e)
100 if (e->button() == TQt::LeftButton)
103 TQRadioButton::mouseReleaseEvent(e);
106 void RadioButton::mouseMoveEvent(TQMouseEvent* e)
109 TQRadioButton::mouseMoveEvent(e);
112 void RadioButton::keyPressEvent(TQKeyEvent* e)
122 case TQt::Key_Escape:
127 TQRadioButton::keyPressEvent(e);
130 void RadioButton::keyReleaseEvent(TQKeyEvent* e)
133 TQRadioButton::keyReleaseEvent(e);