blockly > Événements > CommentChange > course
Exécutez un événement de modification.
Signature :
run(forward: boolean): void;
Paramètres
Paramètre |
Type |
Description |
transférer |
booléen |
"True" si exécution vers l'avant, "false" s'il s'agit d'une exécution arrière (annuler). |
Renvoie :
vide
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2024/08/29 (UTC).
[null,null,["Dernière mise à jour le 2024/08/29 (UTC)."],[[["The `run()` method executes a CommentChange event, modifying a block's comment."],["It accepts a boolean `forward` parameter, indicating whether the event should be applied (forward) or reversed (backward/undo)."],["Calling `run()` with `forward` set to `true` applies the comment change, while setting it to `false` undoes the change."]]],["The `Events.CommentChange.run()` method executes a comment change event. It accepts a boolean parameter, `forward`, which determines the direction of the operation. When `forward` is true, the change is applied; when false, the change is undone. The method does not return any value (void). This method is essential for both implementing changes and enabling the undo functionality for comment edits.\n"]]