Picking IHM
Posted: Mon Jun 22, 2009 12:17
Is there a way to know if one of my layout have been picked , or clicked, in order to avoid my 3D picking.
Thanks
Thanks
Jamarr wrote:The obvious thing to do would be to check the return value for CEGUI::System::getSingleton().injectMouseButtonDown(CEGUI::LeftButton). If it returns true then you know that the mouse clicked on a CEGUI window.
That being said, there is an issue with CEGUI when clicking on a window that is already the active window; see this thread. What you could do is iterate through all of your top-level windows and call CEGUI::Window::isHit on each one, passing in the mouse-coordinates, to determine if the mouse was clicked over a CEGUI window or not...
xabila wrote:So First the CEGUI::System::getSingleton().injectMouseButtonDown(CEGUI::LeftButton) is not working fine.
xabila wrote:I 'm working with lots of transparent layouts and it seems that the injectMouse is catching a transparent window, i guess in order to activate it.
So i was wondering if the isHit method or getWindowContainingMouse are handled transparent layout ?