Hopefully this is a very simple question, though I can't find the answer yet -
How do I stop my windows moving into the foreground / uppermost layer when I click on them? I assume this happens because that window is then in focus. Do I have to set them to disabled to prevent this?
Z-order of windows
Moderators: CEGUI MVP, CEGUI Team
Re: Z-order of windows
Disabling those windows will prevent them from receiving the focus, but for whatever reason does not prevent the currently active window from losing focus (at least in 0.6.2). If this is not sufficient, then the next obvious solution would be to simply not inject the event - after all, you control what input CEGUI receives. You could use Window::isHit() or System::getWindowContainingMouse() to determine what window, if any, the mouse is over. There are probably other means as well. If you explained why you are doing this, giving an exact solution would be easier.
If somebody helps you by replying to your thread, upvote him/her as a thanks! Make sure to include your CEGUI.log and everything you tried when posting! And remember that we are not magicians!
-
- Just popping in
- Posts: 20
- Joined: Mon Jun 08, 2009 06:05
Re: Z-order of windows
Hi Jamarr
Thanks - disabling them worked fine for what I needed.
The problem was because I had a button on top of a StaticImage, so if you accidentally clicked on the image, it would move to the top layer and obscure the button!
Is there any way to disable windows through the .layout file, or is it necessary to do it through code?
Thanks - disabling them worked fine for what I needed.

Is there any way to disable windows through the .layout file, or is it necessary to do it through code?
- CrazyEddie
- CEGUI Project Lead
- Posts: 6760
- Joined: Wed Jan 12, 2005 12:06
- Location: England
- Contact:
Re: Z-order of windows
Hi,
You can set the disabled state in a layout by way of the "Disabled" property. So:
Note also, if you need the thing enabled, you can also try disabling the "RiseOnClick" setting, though note that this was broken in versions prior to 0.6.2 (I think).
CE.
You can set the disabled state in a layout by way of the "Disabled" property. So:
Code: Select all
<Property Name="Disabled" Value="True" />
Note also, if you need the thing enabled, you can also try disabling the "RiseOnClick" setting, though note that this was broken in versions prior to 0.6.2 (I think).
CE.
Useful Links: Forum Guidelines | Documentation | Tutorials | HOWTO | Videos | Donate to CEGUI | CEGUI Twitter
Who is online
Users browsing this forum: No registered users and 19 guests