Re: [patch] adding radio buttons to radio groups



On Fri, Jan 22, 1999 at 04:24:31AM +0100, Tim Janik wrote:
> 
> yeah, you are right, actually radio buttons were meant to be inactive
> upon initial creation, but the unconditional call to
> gtk_radio_button_set_group (group) even for group==NULL in gtk_radio_button_new
> causes automated activation of the radio button upon creation.
> i think the proper fix to this is to really check out the buttons state
> and eventually reset it gtk_radio_button_set_group() so there's always only
> one button active. additionally, we shouldn't call
> gtk_radio_button_set_group (NULL) from gtk_radio_button_new() anymore, and
> need to use gtk_toggle_button_set_active() for the state changes.
> i'll hack something up later this night.
> 

It would seem to make more sense to create them active like
it occurs now as to not break any existing code which might
be relying on that.  

Plus, it makes sense to always have one radio button in a group
selected, and that can't happen if the first one in the group
is not set active.

--
Shawn T. Amundson               
amundson@gimp.org               http://www.gimp.org/~amundson

"The assumption that the universe looks the same in every
 direction is clearly not true in reality." - Stephen Hawking



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