Repository navigation
refactor: UI Toolkit screen elements move into a shared module behind one entry point - #3311
Merged
hatayama merged 1 commit intoOct 13, 2026
Conversation
simulate-mouse-ui is about to find and press UI Toolkit controls the same way screenshot annotations list them, and one tool may not reference another. The panel gathering, picking, element paths and control walk therefore move out of the Screenshot assembly into Common.UIToolkit, behind a single public entry point that works in top-left Game View pixels. Its parts stay internal and are visible only to the tests. Screenshot keeps UIToolkitElementCollector.Collect with the same signature as an adapter: it supplies the uGUI probe points and turns the results back into bottom-left annotation entries with the same conversions in the same order, so annotations are unchanged.
Contributor
|
Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configuration
⛔ Files ignored due to path filters (16)
📒 Files selected for processing (12)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
hatayama
merged commit Oct 13, 2026
63ce71f
into
feature/screenshot-ui-toolkit-annotation
10 of 11 checks passed
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
User Impact
screenshot --annotate-elementsreports the same UI Toolkit entries with the same coordinates.Changes
UnityCLILoop.FirstPartyTools.Common.UIToolkit.Editor(Editor only, not auto-referenced, references Common.MouseUi).UIToolkitScreenElements.CollectControls(probePointsForTopLeftBounds)and result typeUIToolkitScreenControl. Both work in top-left Game View pixels.git mv. Internals are visible to the test assemblies only.GameObjectPathUtility.UIToolkitElementCollector.Collect(elements, gameViewHeight)as an adapter. It supplies the uGUI probe points and converts the results back to bottom-left entries, using the same conversions in the same order as before.Verification
uloop compile: 0 errors. The one warning is an existing one in a test fixture.UIToolkitElementClassifierTests13/13,UIToolkitPanelKindTests4/4,UIToolkitReachabilityProbeTests6/6,UIToolkitScreenMappingTests9/9,UIElementAnnotatorCollectTests11/11,OnionAssemblyDependencyTests83/83.UIToolkitElementCollectorTests18/18.check-asmdef-policy: no violations.scripts/test-screenshot-uitoolkit-annotation.sh: PASS, with the coordinate checks against the elements-only capture (±1 px) passing.git statuswas unchanged after the run.