Mailinglist Archive: yast-devel (55 mails)

< Previous Next >
Re: [yast-devel] Libyui How to use RadioButton and RadioGroupButton
2011/3/28 Manu Gupta <manugupt1@xxxxxxxxx>:
Thanks..  It worked

Now I am trying to dynamically insert items but it seems that it does
not work.. can you have a look at it.

I have tried to options

1. Calling dialog->recalcLayout() and then inserting a YLable
2. Inserting a label and then calling dialog->recalcLayout()

2011/3/28 Josef Reidinger <jreidinger@xxxxxxx>:
Manu Gupta write:
Hi All

I have been trying to use RadioButton and RadioButtonGroup using
libyui but I am unable to do so Can anyone have a look at my code and
tell me how do I do it?

at first thanks for feedback. At second I want to note that I am not author
of libyui and I just fix your code by looking in documentation and source

Mistake you do is that addRadioButton should be called only in constructor
by documentation, but when I look in code it doesn't use at all. Actually
RadioButton detect its group just by searching its parents and match first
radioButtonGroup ( Yes, I also think that it is not perfect solution ).

So I attached modified your code which actually works.

RadioButton use first RadioButtonGroup which it find as its parent.


Josef Reidinger
Appliance Toolkit team
maintainer of perl-Bootloader and parts of webyast and SLMS
author of rubygems - studio_api and net_observer (coauthor)

Manu Gupta

Manu Gupta
< Previous Next >
List Navigation