SFML community forums

General => Feature requests => Topic started by: FRex on November 21, 2013, 10:36:43 pm

Title: Grabbing focus
Post by: FRex on November 21, 2013, 10:36:43 pm
Forcing the sf::Window to be the one that currently has focus and is on top.
On Linux it's XRaiseWindow, on Windows - SetForegroundWindow, in both cases we already store variables needed for the call anyway in the window impl for that platform, I don't know what it is on Mac OS X but I doubt it's much worse.
Title: Re: Grabbing focus
Post by: eXpl0it3r on November 22, 2013, 12:50:37 am
You mean like this thread (http://en.sfml-dev.org/forums/index.php?topic=6623.0)? ;)

Not the same feature at all, but relevant discussion anyways on GitHub (https://github.com/SFML/SFML/pull/493).
Title: Re: Grabbing focus
Post by: FRex on November 22, 2013, 07:52:51 am
More like this thread : http://en.sfml-dev.org/forums/index.php?topic=3817.0
I also found one or two others about getting focus(not setting it) and Laurent just always says there is no such function. :P

Quote
Not the same feature at all, but relevant discussion anyways on GitHub.
Yes, not the same feature at all, it's pinning on top, not stealing focus like after normal mouse click. :P
It's not that relevant, stealFocus(); wouldn't be a style flag, it'd make no sense at all, it doesn't keep or modify any state, it's like a fake mouse click in the window that brings it to top(side effect of grabbing focus by function it seems) and makes it focused, it doesn't keep the focus from going away or anything.