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

Fix "Create Shader Node" window position when visual shader editor is floating #78996

Merged
merged 1 commit into from
Aug 21, 2023

Conversation

Tetane
Copy link
Contributor

@Tetane Tetane commented Jul 3, 2023

Fixes the issue where the "Create shader node" window was appearing inside the boundaries of the main Godot editor window instead of the visual shader editor window when it's floating. (mentioned in issue #78854.)

@Tetane Tetane requested a review from a team as a code owner July 3, 2023 18:36
Copy link
Contributor

@trollodel trollodel left a comment

Choose a reason for hiding this comment

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

I would set the dialog current_screen to the get_window() one, because I'm not sure if the screens space is unified in all platforms.

@Tetane
Copy link
Contributor Author

Tetane commented Jul 3, 2023

@trollodel Something like that: members_dialog->set_current_screen(get_window()->get_current_screen());?
(I only tested on Windows 10, I can't currently test on other platforms.)

@YuriSizov YuriSizov changed the title Fixes "Create shader Node" window position when visual shader editor is floating Fix "Create Shader Node" window position when visual shader editor is floating Jul 5, 2023
@YuriSizov YuriSizov added this to the 4.2 milestone Jul 5, 2023
@trollodel
Copy link
Contributor

trollodel Something like that: members_dialog->set_current_screen(get_window()->get_current_screen());? (I only tested on Windows 10, I can't currently test on other platforms.)

Sorry for the late response, but yes, like that.

Copy link
Contributor

@Sauermann Sauermann left a comment

Choose a reason for hiding this comment

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

Using DisplayServer was the cause of the problem, that this PR fixes.
Have also tested single-window-mode and didn't notice any problems.

During testing I noticed, that it is possible to move the window-title outside of the screen-area, when placing the shader-dock on the top of the screen, but this can also be solved in a separate PR:
image

@akien-mga akien-mga merged commit 23db024 into godotengine:master Aug 21, 2023
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants