How can I change focus to Slate and back?
I'm building a menu in Slate, which toggles after you've hit a keyboard key (as the game itself is not mouse cursor based).
So when I hit this key, I unpossess the pawn to stop it from getting input, I ask my HUD class to make slate widgets visible, the finally set "Show Mouse Cursor" to true on the PlayerController.
When I do that, the Slate layer is not focus. I have to click on my window once, they I can drag scrollbars and such. Put another way, the first click to a button fails, the next one succeed.
After focus has been given to slate, and the menu is hidden, no mouse input goes to the Controller, so again I have to click once.
Hi Guys !
Just SOLVE this problem =), thanks to the ShooterGame !
So basically this is what you have to do :
Add this in your widget :
Then when you want to open the menu simply do that :
And to close it :
Hope this will help you because its been 3 days I am on this !!
answered Jun 19 '14 at 07:13 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here