Stay organized with collections
Save and categorize content based on your preferences.
blockly > DeleteArea > updateWouldDelete_
DeleteArea.updateWouldDelete_() method
Updates the internal wouldDelete_ state.
Signature:
protected updateWouldDelete_(wouldDelete: boolean): void;
Parameters
Parameter |
Type |
Description |
wouldDelete |
boolean |
The new value for the wouldDelete state. |
Returns:
void
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-18 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-18 UTC."],[[["\u003cp\u003eThe \u003ccode\u003eupdateWouldDelete_\u003c/code\u003e method is a protected method within the \u003ccode\u003eDeleteArea\u003c/code\u003e class used to update the internal \u003ccode\u003ewouldDelete_\u003c/code\u003e state.\u003c/p\u003e\n"],["\u003cp\u003eIt takes a boolean parameter \u003ccode\u003ewouldDelete\u003c/code\u003e which represents the new value for the internal state and returns void.\u003c/p\u003e\n"],["\u003cp\u003eThis method is called to signal whether or not a potential block deletion is imminent based on the current drag operation.\u003c/p\u003e\n"]]],["The `updateWouldDelete_` method of the `DeleteArea` class updates the internal `wouldDelete_` state. It accepts a boolean parameter, `wouldDelete`, which represents the new value for this state. This method has no return value (void). The method is protected, meaning it is accessible within the class and its subclasses. The primary action is updating the internal state based on the provided boolean input.\n"],null,["[blockly](./blockly.md) \\\u003e [DeleteArea](./blockly.deletearea_class.md) \\\u003e [updateWouldDelete_](./blockly.deletearea_class.updatewoulddelete__1_method.md)\n\nDeleteArea.updateWouldDelete_() method\n\nUpdates the internal wouldDelete_ state.\n\n**Signature:** \n\n protected updateWouldDelete_(wouldDelete: boolean): void;\n\nParameters\n\n| Parameter | Type | Description |\n|-------------|---------|------------------------------------------|\n| wouldDelete | boolean | The new value for the wouldDelete state. |\n\n**Returns:**\n\nvoid"]]