Bulk Edit Rotate: skip models whose type doesn't support that axis#6521
Merged
derwin12 merged 1 commit intoJun 15, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Adds user-facing handling for Bulk Edit Rotate when selected models don’t meaningfully support rotation on a given axis, preventing “no-op” edits and improving feedback.
Changes:
- Introduces
ModelSupportsRotationAxis()to filter eligible models by screen-location type and axis. - Tracks unsupported models separately and shows a summary dialog listing skipped models (with capped output).
- Adds informative messaging when none of the eligible models support the requested rotation.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+2434
to
+2441
| wxMessageBox( | ||
| wxString::Format( | ||
| "None of the selected models support rotation on the %c axis.\n\n" | ||
| "Skipped:\n%s\n" | ||
| "Arches/CandyCane/Icicles only support X; Lines/PolyLines derive orientation from their endpoints.", | ||
| axis, | ||
| formatSkippedNames(unsupportedModels)), | ||
| "Bulk Edit Rotate", wxOK | wxICON_INFORMATION, this); |
Comment on lines
+2506
to
+2515
| wxMessageBox( | ||
| wxString::Format( | ||
| "Rotated %zu of %zu selected models.\n\n" | ||
| "Skipped because their model type does not support rotation on the %c axis:\n%s\n" | ||
| "Arches/CandyCane/Icicles only support X; Lines/PolyLines derive orientation from their endpoints.", | ||
| editableModels.size(), | ||
| editableModels.size() + unsupportedModels.size(), | ||
| axis, | ||
| formatSkippedNames(unsupportedModels)), | ||
| "Bulk Edit Rotate", wxOK | wxICON_INFORMATION, this); |
Comment on lines
+2508
to
+2512
| "Rotated %zu of %zu selected models.\n\n" | ||
| "Skipped because their model type does not support rotation on the %c axis:\n%s\n" | ||
| "Arches/CandyCane/Icicles only support X; Lines/PolyLines derive orientation from their endpoints.", | ||
| editableModels.size(), | ||
| editableModels.size() + unsupportedModels.size(), |
Comment on lines
+2436
to
+2438
| "None of the selected models support rotation on the %c axis.\n\n" | ||
| "Skipped:\n%s\n" | ||
| "Arches/CandyCane/Icicles only support X; Lines/PolyLines derive orientation from their endpoints.", |
Comment on lines
+2509
to
+2510
| "Skipped because their model type does not support rotation on the %c axis:\n%s\n" | ||
| "Arches/CandyCane/Icicles only support X; Lines/PolyLines derive orientation from their endpoints.", |
Contributor
Author
Rotate X / Y / Z under Bulk Edit was applied unconditionally to every unlocked selected model, but ThreePointScreenLocation (Arches, CandyCane, Icicles) only honors X rotation, and TwoPoint/PolyPoint based models (Lines, PolyLines, etc.) derive their orientation from their endpoints - calling SetRotateY/Z on them stored a value that had no visible effect. Now: each model in the selection is checked against the requested axis. Supported models are rotated; unsupported models are listed in a follow-up message so the user knows exactly what was and wasn't touched. - If no selected model supports the axis (e.g. user picked only Arches and chose Rotate Y), the value-entry dialog is skipped and an info box explains why with the offending model names. - If some support and some don't (e.g. a Matrix + an Arch + Rotate Y), the supported models are rotated and a follow-up info box lists the skipped names, one per line, capped at 20 with "and N more" for huge selections. - If all selected models support the axis, behavior is unchanged (no extra dialog). Includes are already present transitively (same dynamic_cast pattern used at LayoutPanel.cpp:1384). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
90a468c to
a70f94d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
Follow-up to #6184. Bulk Edit → Rotate X / Y / Z applied the rotation unconditionally to every unlocked selected model, but several model types don't actually honor every axis:
SetRotateX/Y/Zstores a value with no visible effect.So a user could bulk-rotate a mixed selection and watch some models silently ignore the action.
Fix
BulkEditRotateAxisnow classifies each selected (unlocked) model into "supported on this axis" or "unsupported", and:Includes are already pulled in transitively (the same
dynamic_cast<ModelWithScreenLocation<BoxedScreenLocation>*>pattern is already used atLayoutPanel.cpp:1384). wx-platform-neutral — works on macOS, Windows, Linux.Test plan
🤖 Generated with Claude Code