8000 fix!: remove deprecated setEnabled and backwards event filtering by maribethb · Pull Request #9039 · google/blockly · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

fix!: remove deprecated setEnabled and backwards event filtering #9039

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

Merged
merged 1 commit into from
May 13, 2025

Conversation

maribethb
Copy link
Contributor

The basics

The details

Resolves

Fixes #9038

Proposed Changes

  • Removes the deprecated setEnabled functions from Block and BlockSvg.
  • Removes the forward parameter from Blockly.Events.filter and updates usages.

BREAKING CHANGES

If you call block.setEnabled, update to call block.setDisabledReason instead. A block could be disabled for multiple reasons, and calling setDisabledReason multiple times for each of these reasons is supported and encouraged. A block will only appear enabled if there are no disabled reasons remaining. Blockly will now manage this state for you.

Calling Blockly.Events.filter() with the forward parameter set to false is no longer supported. If you only call this function with the second parameter set to true you can simply remove the parameter. If you are ever calling this function with the second parameter set to false, you are doing something complex and error-prone. Please get in touch on the forum, or see this PR and the linked issues for context.

@maribethb maribethb requested a review from a team as a code owner May 13, 2025 20:55
@maribethb maribethb requested a review from gonfunko May 13, 2025 20:55
@github-actions github-actions bot added breaking change Used to mark a PR or issue that changes our public APIs. PR: fix Fixes a bug labels May 13, 2025
@maribethb maribethb merged commit 556ee39 into google:rc/v12.0.0 May 13, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change Used to mark a PR or issue that changes our public APIs. PR: fix Fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0