Re: Newbie: GUI builder [message #31685] |
Mon, 05 August 2002 13:40 |
Pavel A. Romashkin
Messages: 531 Registered: November 2000
|
Senior Member |
|
|
Peter wrote:
>
> -I`ve created a Base with Text and Label widgets inside. I want it (the
> base) to enable/desable with a pressButton so all the widgets inside
> become 'false sensitive'. It works as long as the Base is set to
> 'sensitive=true' in the properties of the .prc file. But when set to
> 'false', it becomes impossible to make the Base enabled. Is it normal
> and if yes, is there another way to make it?
I am guessing, the pressButton is on that same base? If so, once the
base is desensitized, the button will be, too. Place the base in another
base, and place the button on the top level base, outside the base you
are turning on/off. Should do the trick. I am not familiar with the GUI
builder (and I am glad I'm not), but this should be trivial if you
actually alter the code.
Cheers,
Pavel
|
|
|
Re: Newbie: GUI builder [message #31688 is a reply to message #31685] |
Mon, 05 August 2002 12:53  |
Rick Towler
Messages: 821 Registered: August 1998
|
Senior Member |
|
|
"Peter" <hookvspan@hotmail.com> wrote
> -I`ve created a Base with Text and Label widgets inside. I want it (the
> base) to enable/desable with a pressButton so all the widgets inside
> become 'false sensitive'. It works as long as the Base is set to
> 'sensitive=true' in the properties of the .prc file. But when set to
> 'false', it becomes impossible to make the Base enabled. Is it normal
> and if yes, is there another way to make it?
Probably. I think that when the widget is desensitized it doesn't receive
system events so making your top level base insensitive blocks all events.
This makes it pretty tough to process events from your button.
What you can do is add another base which is a child of your top level base
which contains all of your text and labels. Your button should NOT be in
this base. You should be able to set this new base's sensitivity property
to whatever you choose while keeping the top level base always sensitive
(making your button always sensitive and "enabled")
-Rick
|
|
|