Radio Buttons

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Radio Buttons

Ian Bartholomew-16
Andy/Blair,

The #defaultStyle for a RadioButton is BS_AUTORADIOBUTTON which allows a
number of buttons with the same parent view to act as a group. However, in
Dolphin 5/Windows XP (unlike my Dolphin 4/Windows 2000 box) the default
state of the RadioButton's #isGroupStop aspect value is true. This negates
the #defaultStyle as it indicates that each button is a group of it's own
and therefore ignores the state of other buttons with the same parent.

I'm not sure why the change to the default state of #isGroupStop was made in
Dolphin 5 (or if it is determined by the OS) but I think it should be
overridden in RadioButton to match the #defaultStyle.

Regards
    Ian


Reply | Threaded
Open this post in threaded view
|

Re: Radio Buttons

Blair McGlashan
"Ian Bartholomew" <[hidden email]> wrote in message
news:qaZR8.8174$xU5.710456@wards...

> Andy/Blair,
>
> The #defaultStyle for a RadioButton is BS_AUTORADIOBUTTON which allows a
> number of buttons with the same parent view to act as a group. However, in
> Dolphin 5/Windows XP (unlike my Dolphin 4/Windows 2000 box) the default
> state of the RadioButton's #isGroupStop aspect value is true. This negates
> the #defaultStyle as it indicates that each button is a group of it's own
> and therefore ignores the state of other buttons with the same parent.
>
> I'm not sure why the change to the default state of #isGroupStop was made
in
> Dolphin 5 (or if it is determined by the OS) but I think it should be
> overridden in RadioButton to match the #defaultStyle.

It is a question of the lesser of two evils - a little inconvenience vs a
lock up: The Windows dialog key processing requires that a group stop be set
on the first button or it goes into an infinite loop when one attempts to
tab. To guarantee this we have turned it on by default, meaning that one has
to turn it off manually in the View Composer (or by evaluating a little
expression) for subsequent buttons that are to be considered part of the
same group.

I've attached the details of the original bug report.

Regards

Blair
-------------------------
Defect No: 102 Date Entered: 06/03/2001 Product: DVE
Entered by: Andy Bower Component: Dolphin
Status: Closed (Fixed) Resolution: Code Change
Type: Incorrect Functionality Priority: Next Major Release Severity:
Workaround
Disposition: Open - Not Reviewed
Reference:

Summary: Radio Buttons in a DialogView cause endless loop
Workaround: A workaround is place the radio buttons inside a ContainerView
rather than directly inside the DialogView.

--- Reported By ---
Found by: Christopher Demers Date Found: 06/03/2001
Version Found: 4.0
Description: To duplicate place one or more RadioButtons from the tool box
(BooleanPresenter.Radio button) on a Dialog view.  Then test it.  As soon as
you activate one of the RadioButtons the Dolphin UI will lock up.  I have
been able to break out via Ctrl-Break.  I find that I have to do that and
terminate twice before I can close the view.  This also happens if you do a
show from the class browser after you save the view.

I can duplicate this on Windows NT as well as a Windows 2000, I have not
tried on other systems.

My quick workaround was to use CheckBox's with code that emulates RadioBox
functionality instead.
Reproduced:
Steps to Reproduce:
User's Computer Configuration
Other Hardware and Software:
Attachments:  none

--- History ---
Fixed by: Blair McGlashan Result: Fix and close Date Fixed: 12/02/2002
Version Fixed: 5.0 beta 3 Fixed Resolution: Code Change Hours to Fix:  0.50
Affects Documentation: No Affects Test Plan: No
Notes: This is a manifestation of the "Dialog navigation goes into infinite
loop sending WM_GETDLGCODE" Windows bug. It is occurring because in a raw
dialog there is no subsequent 'group' to tab to. The OK button is now marked
as a group stop. It has also been necessary to mark the radio button as a
group stop in its toolbox resource, and it will be necessary to manually
turn this off on radio buttons added after the first in a group.

Created by: Andy Bower Date of creation: 06/03/2001 Creation method: Add
Defect window Last modified by: Blair McGlashan Date of last modification:
12/02/2002


Reply | Threaded
Open this post in threaded view
|

Re: Radio Buttons

Ian Bartholomew-16
Blair,

> It is a question of the lesser of two evils - a little inconvenience vs a
> lock up:

That seems fair enough, thanks for the explanation.

It's not particularly inconvenient either (now I know what the problem is)
as I tend to use my RadioButtonGroup goodie whenever I need a group of
interconnected RadioButtons so I should be able to make that automatically
change the #isGroupSetting to false in all it's children.

Regards
    Ian