Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overlay end up behind Gw2 window #1

Open
Rador opened this issue Sep 26, 2013 · 0 comments
Open

Overlay end up behind Gw2 window #1

Rador opened this issue Sep 26, 2013 · 0 comments

Comments

@Rador
Copy link

Rador commented Sep 26, 2013

When clicking outside the Gw2 window, for example in a internet browser on another screen and then clicking back in, the Gw2 window more often then not end up on top of the cursor overlay witch makes it invisible. The solution i have used for that until now have been to restart the cursor overlay but that have become quite annoying. So after looking at the code a bit i found that adding WinSetOnTop($overlay, "", 1) and WinSetOnTop($overlay, "", 0) to ShowOverlay() and HideOverlay() fixed this issue.

Func ShowOverlay()
   Global $overlay, $overlayVisible = True
   WinSetOnTop($overlay, "", 1)
   GUISetState(@SW_SHOWNOACTIVATE, $overlay)
   Local $mouse = MouseGetPos()
   MoveOverlay($mouse[0], $mouse[1])
EndFunc

Func HideOverlay()
   Global $overlay, $overlayVisible = False
   WinSetOnTop($overlay, "", 0)
   GUISetState(@SW_HIDE, $overlay)
EndFunc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant