Repository navigation
FIX: [Port] [ISX-3179] Fixed Input Device Debugger window staying subscribed after closing - #2510
Open
josepmariapujol-unity wants to merge 1 commit into
Conversation
…scribed after closing InputDeviceDebuggerWindow.OnDestroy subscribed to EditorApplication.playModeStateChanged instead of unsubscribing, so closed windows stayed referenced by the event until the next domain reload. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
💡 Harness Review
The change correctly pairs the Play mode event subscription with unsubscription when the debugger window closes. I examined initialization, teardown, Play mode callbacks, and the changelog entry; no actionable issues were found.
Reviewed commit 86eec90
🤖 Helpful? 👍/👎
Codecov ReportAttention: Patch coverage is
@@ Coverage Diff @@
## develop #2510 +/- ##
===========================================
+ Coverage 78.96% 79.22% +0.25%
===========================================
Files 767 769 +2
Lines 140949 141283 +334
===========================================
+ Hits 111305 111926 +621
+ Misses 29644 29357 -287 Flags with carried forward coverage won't be shown. Click here to find out more.
|
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.
Port of trunk PR #140581
Description
Fixes ISX-3179 (port ticket ISX-3183):
InputDeviceDebuggerWindow.OnDestroysubscribed toEditorApplication.playModeStateChanged(+=) instead of unsubscribing (-=).Each closed Input Device Debugger window stayed referenced by the static event and kept receiving Play mode changes until the next domain reload. With domain reload disabled in Enter Play Mode settings, closed windows built up. Nothing visible broke, because
Repaint()does nothing on a destroyed window, so the effect was a managed memory leak.The fix changes
+=to-=inOnDestroy.Testing status & QA
Found by reading the code. No new test: the only effect is that closed windows are no longer kept alive by the event.
QA: open Window > Analysis > Input Debugger, double-click a device to open its debugger window, close it, then enter and exit Play mode. With a breakpoint in
OnPlayModeChange, it should no longer be hit for the closed window.Overall Product Risks
Comments to reviewers
The port merged into
developwith no conflicts; the code change is identical to trunk. This PR is a draft until the trunk PR lands.Description written by Claude Code (Claude Opus 5.5) on behalf of the author.
Checklist
Before review:
Changed,Fixed,Addedsections.Area_CanDoX,Area_CanDoX_EvenIfYIsTheCase,Area_WhenIDoX_AndYHappens_ThisIsTheResult.During merge:
NEW: ___.FIX: ___.DOCS: ___.CHANGE: ___.RELEASE: 1.1.0-preview.3.