feat(window): add command to set fullscreen on specific monitor#14926
Open
Oscar3170 wants to merge 1 commit intotauri-apps:devfrom
Open
feat(window): add command to set fullscreen on specific monitor#14926Oscar3170 wants to merge 1 commit intotauri-apps:devfrom
Oscar3170 wants to merge 1 commit intotauri-apps:devfrom
Conversation
Author
|
The naming and function parameters could cause confusion, since the other set_fullscreen functions can set the fullscreen state on or off, while this new function only sets fullscreen on. I figured it would be best to leave the job of turning off the fullscreen state to the regular set_fullscreen function, since the monitor is irrelevant in this case. Be free to give feedback on if I should change the name or add a bool parameter to the function. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a new command to the window core plugin
set_fullscreen_on_monitorwhich receives a position and sets the window as fullscreen on the monitor that contains the position.Since tao already exposes a way to specify the monitor for the fullscreen function, it was only necessary to expose this parameter in the tauri-runtime-wry and window plugin.
Since monitor names are not unique the new function needs the monitor's position to know which monitor we actually want.
This is the most useful on wayland systems, since the window can't move itself any other way, and this at least gives an option for applications that need to be fullscreen.
Workaround for issues: #14019 and #7376.