Skip to content

Conversation

lizlooney
Copy link
Collaborator

Update mrc_get_parameter to respond to mrcOnMove and mrcOnAncestorMove, instead of using change_framework.

Changed type Parameter to interface Parameter and export it.
Added method mrcGetParameterNames.

In mrc_event.ts:
Import Parameter from mrc_class_method_def.ts.
Fixed comment for mrcOnMove.

In mrc_event_handler.ts:
Import Parameter from mrc_class_method_def.ts.
Added method mrcGetParameterNames.

In mrc_get_parameter.ts:
Added constants FIELD_PARAMETER_NAME and WARNING_ID_GET_PARAMETER.
Removed parameterType from GET_PARAMETER_BLOCK.
Added mrcParameterType and mrcHasWarning to GetParameterMixin.
Replaced onBlockChanged with mrcOnMove, mrcOnAncestorMove, and checkBlockPlacement.
Updated checkBlockPlacement to call mrcGetParameterNames on the root block if it is a
mrc_class_method_def or mrc_event_handler block.

In editor.ts:
Added code to call mrcOnAncestorMove for all descendants of the block that was moved.
@lizlooney lizlooney requested a review from alan412 October 2, 2025 05:16
Copy link
Collaborator

@alan412 alan412 left a comment

Choose a reason for hiding this comment

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

LGTM.

Thank you for splitting out the reformatting as a separate commit. It made reviewing this MUCH easier!!

@alan412 alan412 merged commit 9565afd into wpilibsuite:main Oct 3, 2025
1 check passed
@lizlooney lizlooney deleted the pr_get_parameter_move branch October 4, 2025 02:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants