Page 1 of 1

[Solved] How to hide cursor in CEGUI 0.8.3

Posted: Sun Mar 23, 2014 11:27
by superpws
I want to hide the cursor so I searched the forum/google to know how to do so. All links points to

Code: Select all

CEGUI::MouseCursor::getSingleton().hide();

but getSingleton() isn't the member of CEGUI::MouseCursor anymore, so how do I hide the cursor now? I tried

Code: Select all

CEGUI::MouseCursor cursor;
cursor.hide();

but it didn't work (as expected since we won't get current cursor pointer with that).

Thank you.

Re: How to hide cursor in CEGUI 0.8.3

Posted: Sun Mar 23, 2014 14:33
by Kulik
Hi,
get your cursor from your GUIContext.

Code: Select all

System::getSigleton().getDefaultGUIContext().getMouseCursor();

Re: How to hide cursor in CEGUI 0.8.3

Posted: Sun Mar 23, 2014 15:33
by superpws
Thanks, it works!

Code: Select all

CEGUI::System::getSingleton().getDefaultGUIContext().getMouseCursor().hide();

It would be helpful to others who might look for it :)