[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Proxy for RadioButton


Btw. if the object is locked it should not raise events. Thus you can
simply write:

Public Sub rbtnGroup1_Click()

    For Each hRB As ToggleButton In Action["rbG1"].Controls
      Object.Lock(hRB)
        If hRB <> Last Then
           hRB.Value = False
        Else
          hRB.Value = True
        Endif
      Object.UnLock(hRB)
    Next

End

No need for handling MouseUp event.

Jussi

On Sun, Sep 22, 2024 at 10:36 PM Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx>
wrote:

> Why not?
>> What's wrong with it?
>>
>> only i guess if QT decide a single radio within a parent container cannot
>> be set to False like GTK3 does
>>
>
> Well, maybe I'm wrong, but by quick look I couldn't find the behavior of a
> single radiobutton defined. Thus I think that is (unnecessary) misuse of
> the control and no guarantee that the undefined behavior is kept that way.
> Infact I think GTK3 got it right, radiobutton is meant for selecting
> exclusively one option and thus selecting none is incorrect.
> Instead use togglebuttons and it works also in GTK3.
>
> Jussi
>
>
>
>

Follow-Ups:
Re: Proxy for RadioButtonGianluigi <gradobag@xxxxxxxxxxx>
References:
Proxy for RadioButtonBB <adamnt42@xxxxxxxxx>
Re: Proxy for RadioButtonJussi Lahtinen <jussi.lahtinen@xxxxxxxxx>
Re: Proxy for RadioButtonBB <adamnt42@xxxxxxxxx>
Re: Proxy for RadioButtonBruce Steers <bsteers4@xxxxxxxxx>
Re: Proxy for RadioButtonJussi Lahtinen <jussi.lahtinen@xxxxxxxxx>
Re: Proxy for RadioButtonBruce Steers <bsteers4@xxxxxxxxx>
Re: Proxy for RadioButtonJussi Lahtinen <jussi.lahtinen@xxxxxxxxx>