Hello,
why doesnt show on a window affect the children which is set to shown ? Shouldnt this be the task of the window manager ?
- Kristian
show / hide ?
Moderators: CEGUI MVP, CEGUI Team
- spannerman
- Home away from home
- Posts: 330
- Joined: Wed Jan 12, 2005 12:06
Re: show / hide ?
Hi kristian,
In my CEGUI apps, if I set a windows visibility to false, then all the contained windows / widgets are also hidden, and they are shown when the parent windows visibility is set to true.
So Im not sure I understand your problem, please be a bit more descriptive. Maybe post an example?
In my CEGUI apps, if I set a windows visibility to false, then all the contained windows / widgets are also hidden, and they are shown when the parent windows visibility is set to true.
So Im not sure I understand your problem, please be a bit more descriptive. Maybe post an example?
Re: show / hide ?
For example: I have a layout with 2 windows one is a menu and the other is a error window.
As per default the error window should of course not be shown so i set the visible property to false in the layout. Unfortunally when i want to show the error window i need to call show for each of the children like the text widget showing the error message. If i only call show for the error window the children is not shown automaticly.
The children has their visible prop. set to true in the layout.
Regards
Kristian
As per default the error window should of course not be shown so i set the visible property to false in the layout. Unfortunally when i want to show the error window i need to call show for each of the children like the text widget showing the error message. If i only call show for the error window the children is not shown automaticly.
The children has their visible prop. set to true in the layout.
Regards
Kristian
- spannerman
- Home away from home
- Posts: 330
- Joined: Wed Jan 12, 2005 12:06
Re: show / hide ?
Hmmm, ok try NOT setting the visibility of the children (to either true or false). By default, when you add a widget it is visible, but perhaps because you are force setting them as visible they may no longer get toggled according to the parent window.
So, just change the visibility of the parent window (e.g. your error window) and the children should appear/ disappear along with that.
If it still doesnt work, post a section of your code here where you are creating these windows and I'll take a look.
So, just change the visibility of the parent window (e.g. your error window) and the children should appear/ disappear along with that.
If it still doesnt work, post a section of your code here where you are creating these windows and I'll take a look.
Re: show / hide ?
I'd guess what is happening is that when you specify the visibility in the layout, the child windows adopt their parent's default upon creation. So instead, leave everything visible in the layout, and then in code just toggle the root window to whatever you need.
Return to “Modifications / Integrations / Customisations”
Who is online
Users browsing this forum: No registered users and 15 guests