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

Save scene when saving built-in resource #84630

Merged

Conversation

KoBeWi
Copy link
Member

@KoBeWi KoBeWi commented Nov 8, 2023

When saving a built-in script in script editor, the scene is saved instead.
When saving a built-in shader, an EditorFileSystemDialog appears.

I wanted to make shader editor's behavior match the script editor, but then I noticed that every resource is saved using EditorNode's save_resource() method, I thought "why not apply this to everything?". And so I did. Now if saving any built-in resource in any editor, its scene is saved. Previously it would bring up a file dialog, as if using the Save As option.

@KoBeWi KoBeWi added this to the 4.x milestone Nov 8, 2023
@KoBeWi KoBeWi requested a review from a team as a code owner November 8, 2023 20:11
editor/editor_node.cpp Outdated Show resolved Hide resolved
@YuriSizov YuriSizov modified the milestones: 4.3, 4.2 Nov 13, 2023
Copy link
Member

@akien-mga akien-mga left a comment

Choose a reason for hiding this comment

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

Looks good to me, we agreed with Yuri that this is likely important to merge for 4.2 to fix annoyances with builtin shaders, now that Ctrl+S defaults to saving the shader.

@KoBeWi KoBeWi force-pushed the what_belongs_to_scene_saves_the_scene branch from d82a33c to da55c06 Compare November 13, 2023 15:34
@akien-mga akien-mga merged commit 80a9f21 into godotengine:master Nov 13, 2023
15 checks passed
@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.

3 participants