-
Notifications
You must be signed in to change notification settings - Fork 657
DYN-9202: Fix node overlays when opening file #16405
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
base: master
Are you sure you want to change the base?
Conversation
Added explicit Opacity property
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See the ticket for this pull request: https://jira.autodesk.com/browse/DYN-9202
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes node overlays when opening files in Dynamo by correcting the visibility state of node overlays and improving the related test coverage. The fix addresses an issue where node overlays were not properly displayed when files were opened.
- Removes the "Failure" category from a previously failing test to re-enable it
- Adds validation for initial overlay state before zoom level adjustments
- Corrects the assertion logic for zoom-in behavior to check visibility instead of opacity
- Sets proper initial opacity for the zoom-in color overlay
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
test/DynamoCoreWpf3Tests/NodeViewTests.cs | Re-enables test and adds assertions for initial overlay state and corrects zoom-in visibility check |
src/DynamoCoreWpf/Views/Core/NodeView.xaml.cs | Sets initial opacity for nodeColorOverlayZoomIn to 0.5 |
@@ -404,7 +407,7 @@ public void ZoomChangeVisibilityTest() | |||
// Zoom in, more than 0.4 | |||
wvm.Zoom = 0.6; | |||
Assert.AreEqual(nodeViewWarningWarningFrozenHidden.zoomGlyphsGrid.Visibility, System.Windows.Visibility.Collapsed); | |||
Assert.AreEqual(nodeViewWarningWarningFrozenHidden.nodeColorOverlayZoomOut.Opacity, 0); | |||
Assert.AreEqual(nodeViewWarningWarningFrozenHidden.nodeColorOverlayZoomOut.Visibility, System.Windows.Visibility.Collapsed); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This assertion is checking the visibility of nodeColorOverlayZoomOut, but based on the context and the previous line checking zoomGlyphsGrid visibility, this should likely be checking nodeColorOverlayZoomIn instead, as the test is verifying zoom-in behavior (zoom = 0.6).
Assert.AreEqual(nodeViewWarningWarningFrozenHidden.nodeColorOverlayZoomOut.Visibility, System.Windows.Visibility.Collapsed); | |
Assert.AreEqual(nodeViewWarningWarningFrozenHidden.nodeColorOverlayZoomIn.Visibility, System.Windows.Visibility.Collapsed); |
Copilot uses AI. Check for mistakes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You've changed nodeColorOverlayZoomIn
, so the question also arises if there are tests to test this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nodeColorOverlayZoomOut
is collapsed so it's opacity does not matter, that is what I updated in this test.
For nodeColorOverlayZoomIn
that is always visible and set to 0.5 opacity since that is controlled by frozen state not zoom. We do not have any tests for the specific wpf control but there are tests for frozen state.
failing tests have been fixed in other PRs https://master-5.jenkins.autodesk.com/job/Dynamo/job/DynamoSelfServe/job/pullRequestValidation/18238/ |
Purpose
Fix node overlays when opening file, also added/updated the test
Declarations
Check these if you believe they are true
*.resx
filesRelease Notes
Fix node overlays when opening file, also added/updated the test
Reviewers
(FILL ME IN) Reviewer 1 (If possible, assign the Reviewer for the PR)
(FILL ME IN, optional) Any additional notes to reviewers or testers.
FYIs
(FILL ME IN, Optional) Names of anyone else you wish to be notified of