Skip to content

Screen position bug fix#1916

Merged
flyinghead merged 2 commits intoflyinghead:devfrom
nexus382:screen-position-bug-fix
Apr 28, 2025
Merged

Screen position bug fix#1916
flyinghead merged 2 commits intoflyinghead:devfrom
nexus382:screen-position-bug-fix

Conversation

@nexus382
Copy link
Contributor

Flycast has a bug that happens when you have multiple monitors.

If I have 2 monitors running, and move Flycast to monitor 2, then exit, it saves so the next time you load up Flycast it will start on that screen. This is nice until you unplug the 2nd monitor before changing it back. When this happens, you can start Flycast but cannot see it, unless you press F11 to make it fullscreen, but then when you hit it again, it goes back to the screen not plugged in and cannot be seen.

I decided to add a check that verifies if the saved window position is on a currently connected display. If not, it resets the window position to the primary display, preventing Flycast from opening on a monitor that is no longer connected and becoming invisible to the user.

@Tails86
Copy link
Contributor

Tails86 commented Apr 28, 2025

Confirmed: this fixes the issue.

Environment: two monitors setup with Windows 11, primary and secondary
Steps:

  1. Start flycast
  2. Move flycast window to secondary screen
  3. Close flycast
  4. Disconnect secondary screen from PC
  5. Restart flycast

Before change, flycast would be invisible, and Win+Left does not work for flycast. After change, flycast appears on primary monitor. flycast still shows up on secondary monitor if step (4) is omitted.

@flyinghead flyinghead merged commit f62582a into flyinghead:dev Apr 28, 2025
15 checks passed
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

Successfully merging this pull request may close these issues.

3 participants