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

Change bulk_theme_override variable to an integer #91563

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

peachey2k2
Copy link

@peachey2k2 peachey2k2 commented May 4, 2024

TL;DR: The value being a boolean caused issues with editor plugins that modified active themes. Even when the user calls begin_bulk_theme_override() themselves, engine would internally call begin_bulk_theme_override() and end_bulk_theme_override(), essentially overwriting the previous override call.

Related proposal

Bugsquad edit: Closes godotengine/godot-proposals#9672

@AThousandShips AThousandShips changed the title change bulk_theme_override variable to an integer Change bulk_theme_override variable to an integer May 4, 2024
@KoBeWi
Copy link
Member

KoBeWi commented May 5, 2024

The new behavior needs to be noted in the documentation of bulk_theme_override methods.

EDIT:
While this is a simple change, it does not come without consequences. If someone had a code where bulk operation begins multiple times without ending it, now it will stop working without any error. idk if it's something worth being concerned about. It would've been easier if begin_bulk_theme_override() had resulted in an error when the operation was already started; the risk of breaking code now would be non-existent.

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.

Add seperate bulk theme override functions to be used seperately from editor
3 participants