[PR #146] [MERGED] fix: removing black bars when auto window size is enabled #1484

Closed
opened 2026-03-03 19:07:17 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/PlayCover/PlayCover/pull/146
Author: @JoseMoreville
Created: 8/9/2022
Status: Merged
Merged: 8/9/2022
Merged by: @JoseMoreville

Base: developHead: hades-dev


📝 Commits (1)

  • f9096da fix: removing black bars when auto window size is enabled

📊 Changes

1 file changed (+4 additions, -2 deletions)

View changed files

📝 PlayCover/View/PlayAppView.swift (+4 -2)

📄 Description

I changed from visibleFrame to frame to calculate screen aspect ratio so we can have full size on full screen when auto window size is enabled.

if app.settings.enableWindowAutoSize {
                    // Float(NSScreen.main?.visibleFrame.width ?? 1920)
                    app.settings.gameWindowSizeWidth = Float(NSScreen.main?.frame.width ?? 1920)
                    // Float(NSScreen.main?.visibleFrame.height ?? 1080)
                    app.settings.gameWindowSizeHeight = Float(NSScreen.main?.frame.height ?? 1080)
                }

The difference with visible frame is that frame takes the space taken by the dock and menu bar.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/PlayCover/PlayCover/pull/146 **Author:** [@JoseMoreville](https://github.com/JoseMoreville) **Created:** 8/9/2022 **Status:** ✅ Merged **Merged:** 8/9/2022 **Merged by:** [@JoseMoreville](https://github.com/JoseMoreville) **Base:** `develop` ← **Head:** `hades-dev` --- ### 📝 Commits (1) - [`f9096da`](https://github.com/PlayCover/PlayCover/commit/f9096daf180e145663fccffc5e8f7972487cf008) fix: removing black bars when auto window size is enabled ### 📊 Changes **1 file changed** (+4 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `PlayCover/View/PlayAppView.swift` (+4 -2) </details> ### 📄 Description I changed from visibleFrame to frame to calculate screen aspect ratio so we can have full size on full screen when auto window size is enabled. ```swift if app.settings.enableWindowAutoSize { // Float(NSScreen.main?.visibleFrame.width ?? 1920) app.settings.gameWindowSizeWidth = Float(NSScreen.main?.frame.width ?? 1920) // Float(NSScreen.main?.visibleFrame.height ?? 1080) app.settings.gameWindowSizeHeight = Float(NSScreen.main?.frame.height ?? 1080) } ``` The difference with visible frame is that frame takes the space taken by the dock and menu bar. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 19:07:17 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/PlayCover#1484
No description provided.