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

[client,sdl] Always disable decorations in multimon session #9957

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

caseif
Copy link
Contributor

@caseif caseif commented Mar 8, 2024

This pull request modifies the code responsible for enabling/disabling borders on FreeRDP windows to consider whether the current session is multimonitor. IMO it doesn't really make sense for a multimonitor session to have borders, and removing the effective requirement that window decorations be explicitly disabled in this case makes for a nicer experience.

Additionally, this code was causing my graphics driver to sometimes hang when initially opening the windows, I would assume due to the combination of SDL_WINDOW_BORDERLESS and SDL_SetWindowBordered(SDL_TRUE). As far as I can tell this is a bug in KWin 6, but removing this trigger is also nice.

@freerdp-bot
Copy link

Can one of the admins verify this patch?

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

client/SDL/sdl_disp.cpp Show resolved Hide resolved
client/SDL/sdl_disp.cpp Show resolved Hide resolved
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

client/SDL/sdl_disp.cpp Outdated Show resolved Hide resolved
client/SDL/sdl_disp.cpp Outdated Show resolved Hide resolved
Copy link

github-actions bot commented Mar 8, 2024

clang-tidy review says "All clean, LGTM! 👍"

Copy link
Member

@akallabeth akallabeth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, you missed a case ;)

there is the exit fullscreen key combination, then it makes sense for multimonitor sessions to have decorations.

@caseif
Copy link
Contributor Author

caseif commented Mar 13, 2024

Would it be sufficient to handle this case by updating the borders when the fullscreen state changes? Also, is it strictly necessary that the borders be updated for all window events? If not it may simplify things to move this code to sdl_create_windows since presumably the other settings won't be changing after window creation, but I'm not sure whether any target platforms mess with window decorations in other cases.

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.

None yet

3 participants