Skip to content

Conversation

@K-Tone
Copy link
Collaborator

@K-Tone K-Tone commented Nov 14, 2025

Description

Here we deprecate the useIMGUIEditorForAssets feature flag.

The aim is to reduce total variability caused by having to keep code that can worth both ways - with uitk and without. We've had the uitk code running for a while now, and with the minimum supported Editor 22.3 TLS we no longer have to care about the case when uitk wasn't available.

Testing status & QA

Local testing

Overall Product Risks

  • Complexity: Low
  • Halo Effect: Low

Checklist

Before review:

  • Changelog entry added.
    • Explains the change in Changed, Fixed, Added sections.
    • For API change contains an example snippet and/or migration example.
    • JIRA ticket linked, example (case %%). If it is a private issue, just add the case ID without a link.
    • Jira port for the next release set as "Resolved".
  • Tests added/changed, if applicable.
    • Functional tests Area_CanDoX, Area_CanDoX_EvenIfYIsTheCase, Area_WhenIDoX_AndYHappens_ThisIsTheResult.
    • Performance tests.
    • Integration tests.
  • Docs for new/changed API's.
    • Xmldoc cross references are set correctly.
    • Added explanation how the API works.
    • Usage code examples added.
    • The manual is updated, if needed.

During merge:

  • Commit message for squash-merge is prefixed with one of the list:
    • NEW: ___.
    • FIX: ___.
    • DOCS: ___.
    • CHANGE: ___.
    • RELEASE: 1.1.0-preview.3.

@K-Tone K-Tone marked this pull request as ready for review November 14, 2025 14:43
@u-pr-agent
Copy link
Contributor

u-pr-agent bot commented Nov 14, 2025

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪

The PR touches many files, but the changes are highly repetitive and consist of removing obsolete IMGUI code paths, making the review straightforward.
🏅 Score: 95

The PR provides a great and systematic cleanup by deprecating and removing old IMGUI code. A minor typo was found.
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Typo

There's a typo in the constant string variable tolltip. It should be tooltip.

private const string tolltip = "Determine which axis 'wins' if both are actuated at the same time. "
  • Update review

🤖 Helpful? Please react with 👍/👎 | Questions❓Please reach out in Slack #ask-u-pr-agent

@K-Tone K-Tone changed the title Anthony/deprecate useimguiforassets CHANGE: Deprecate useIMGUIEditorForAssets Nov 14, 2025
@codecov-git.colasdn.top
Copy link

codecov-git.colasdn.top bot commented Nov 14, 2025

Codecov Report

Attention: Patch coverage is 35.71429% with 9 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...com.unity.inputsystem/InputSystem/InputSettings.cs 25.00% 3 Missing ⚠️
...putSystem/Actions/Interactions/PressInteraction.cs 0.00% 2 Missing ⚠️
...em/InputSystem/Actions/Composites/AxisComposite.cs 0.00% 1 Missing ⚠️
...InputSystem/Actions/Composites/Vector2Composite.cs 0.00% 1 Missing ⚠️
...InputSystem/Actions/Composites/Vector3Composite.cs 0.00% 1 Missing ⚠️
...System/Actions/Interactions/MultiTapInteraction.cs 0.00% 1 Missing ⚠️
@@             Coverage Diff             @@
##           develop    #2283      +/-   ##
===========================================
+ Coverage    76.81%   76.91%   +0.10%     
===========================================
  Files          476      476              
  Lines        88726    88733       +7     
===========================================
+ Hits         68155    68252      +97     
+ Misses       20571    20481      -90     
Flag Coverage Δ
inputsystem_MacOS_2022.3 5.54% <0.00%> (+0.15%) ⬆️
inputsystem_MacOS_2022.3_project 75.49% <7.14%> (+0.79%) ⬆️
inputsystem_MacOS_6000.0 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_MacOS_6000.0_project 77.41% <35.71%> (+0.80%) ⬆️
inputsystem_MacOS_6000.2 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_MacOS_6000.2_project 77.40% <35.71%> (+0.80%) ⬆️
inputsystem_MacOS_6000.3 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_MacOS_6000.3_project 77.40% <35.71%> (+0.80%) ⬆️
inputsystem_MacOS_6000.4 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_MacOS_6000.4_project 77.42% <35.71%> (+0.80%) ⬆️
inputsystem_MacOS_6000.5 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_MacOS_6000.5_project 77.41% <35.71%> (+0.80%) ⬆️
inputsystem_Ubuntu_2022.3 5.55% <0.00%> (+0.15%) ⬆️
inputsystem_Ubuntu_2022.3_project 75.29% <7.14%> (+0.79%) ⬆️
inputsystem_Ubuntu_6000.0 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Ubuntu_6000.0_project 77.21% <35.71%> (+0.80%) ⬆️
inputsystem_Ubuntu_6000.2 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Ubuntu_6000.2_project 77.21% <35.71%> (+0.81%) ⬆️
inputsystem_Ubuntu_6000.3 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Ubuntu_6000.3_project 77.21% <35.71%> (+0.80%) ⬆️
inputsystem_Ubuntu_6000.4 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Ubuntu_6000.4_project 77.22% <35.71%> (+0.80%) ⬆️
inputsystem_Ubuntu_6000.5 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Ubuntu_6000.5_project 77.22% <35.71%> (+0.80%) ⬆️
inputsystem_Windows_2022.3 5.54% <0.00%> (+0.15%) ⬆️
inputsystem_Windows_2022.3_project 75.62% <7.14%> (+0.80%) ⬆️
inputsystem_Windows_6000.0 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_Windows_6000.0_project 77.53% <35.71%> (+0.80%) ⬆️
inputsystem_Windows_6000.2 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_Windows_6000.2_project 77.53% <35.71%> (+0.81%) ⬆️
inputsystem_Windows_6000.3 5.32% <0.00%> (+0.14%) ⬆️
inputsystem_Windows_6000.3_project 77.53% <35.71%> (+0.80%) ⬆️
inputsystem_Windows_6000.4 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Windows_6000.4_project 77.54% <35.71%> (+0.80%) ⬆️
inputsystem_Windows_6000.5 5.33% <0.00%> (+0.14%) ⬆️
inputsystem_Windows_6000.5_project 77.54% <35.71%> (+0.81%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
Assets/Tests/InputSystem/CoreTests_Actions.cs 97.78% <ø> (+<0.01%) ⬆️
Assets/Tests/InputSystem/CoreTests_Analytics.cs 99.27% <ø> (-0.02%) ⬇️
...nputSystem/Actions/Interactions/HoldInteraction.cs 72.09% <ø> (+4.70%) ⬆️
...tSystem/Actions/Interactions/SlowTapInteraction.cs 54.83% <ø> (+4.83%) ⬆️
...InputSystem/Actions/Interactions/TapInteraction.cs 71.73% <ø> (+4.39%) ⬆️
...ystem/Controls/Processors/AxisDeadzoneProcessor.cs 51.72% <ø> (+4.84%) ⬆️
...stem/Controls/Processors/StickDeadzoneProcessor.cs 62.16% <ø> (+4.66%) ⬆️
...InputSystem/Editor/Analytics/InputBuildAnalytic.cs 77.52% <ø> (-0.74%) ⬇️
...nputSystem/Editor/AssetEditor/ParameterListView.cs 49.11% <100.00%> (+9.04%) ⬆️
...Editor/UITKAssetEditor/InputActionsEditorWindow.cs 49.65% <ø> (+0.33%) ⬆️
... and 7 more

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@K-Tone K-Tone requested a review from ekcoh November 18, 2025 09:50
// We simply assign the changed value back to the 'target' object. The input
// system will automatically detect a change in value.
target.scaleFactor = EditorGUILayout.Slider(m_ScaleFactorLabel, currentValue, 0, 2);
}
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

OnGUI is public, unfortunately. So we can't kill those in this PR without releasing a new major version.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Minor: I am the sort of person that like a comment in the code in that case, exactly what you said "motivating it" instead of make it look like a mistake. E.g.

public override void OnGUI()
{
   // Intentionally empty, OnGUI() is public and abstract so has to be implemented. 
}

Copy link
Collaborator

Choose a reason for hiding this comment

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

Just makes it quicker to review/look at since it activates less brain cells when looking at the same code 2 years later :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I hope we won't have these guys in 2 years from now, we should kill with the upcoming move to trunk

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

But I agree. I'd prefer to have this landed though, but if you insist I'll go back and add the comment everywhere.

@K-Tone K-Tone force-pushed the anthony/deprecate-useimguiforassets branch from c5a98a1 to 9493240 Compare November 18, 2025 16:19
}

// handled by OnDrawVisualElements with UI Toolkit
if (!InputSystem.settings.useIMGUIEditorForAssets)
Copy link
Collaborator Author

@K-Tone K-Tone Nov 18, 2025

Choose a reason for hiding this comment

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

Most likely this was a bug having the check this low, after the if block above: because it also deals with the imgui stuff really. The uitk path in this file seems to subscribe to changes in other way.

Copy link
Collaborator

@ekcoh ekcoh left a comment

Choose a reason for hiding this comment

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

Great to see another review cleaning things up! Good work.

// We simply assign the changed value back to the 'target' object. The input
// system will automatically detect a change in value.
target.scaleFactor = EditorGUILayout.Slider(m_ScaleFactorLabel, currentValue, 0, 2);
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Minor: I am the sort of person that like a comment in the code in that case, exactly what you said "motivating it" instead of make it look like a mistake. E.g.

public override void OnGUI()
{
   // Intentionally empty, OnGUI() is public and abstract so has to be implemented. 
}

// We simply assign the changed value back to the 'target' object. The input
// system will automatically detect a change in value.
target.scaleFactor = EditorGUILayout.Slider(m_ScaleFactorLabel, currentValue, 0, 2);
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Just makes it quicker to review/look at since it activates less brain cells when looking at the same code 2 years later :)


### Changed
- Project-Wide Input Actions support can no longer be disabled (removed the UNITY_INPUT_SYSTEM_PROJECT_WIDE_ACTIONS define). (ISX-2397)
- Project-Wide Input Actions support can no longer compiled out (removed the UNITY_INPUT_SYSTEM_PROJECT_WIDE_ACTIONS define). (ISX-2397)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Minor: UNITY_INPUT_SYSTEM_PROJECT_WIDE_ACTIONS (fixed/code formatting style)

private GUIContent[] m_ParameterLabels;

// .Item1 is text, .Item2 is tooltip
private Tuple<string, string>[] m_ParameterLabels;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Might this even be ValueTuple to reduce object allocation?


// Create parameter labels.
m_ParameterLabels = new GUIContent[m_Parameters.Length];
m_ParameterLabels = new Tuple<string, string>[m_Parameters.Length];
Copy link
Collaborator

Choose a reason for hiding this comment

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

Might this even be value tuple to reduce object allocation?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yeah I think you're right, I could do that too

Copy link
Collaborator

@ekcoh ekcoh left a comment

Choose a reason for hiding this comment

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

Marking this as "request changes" only for sake of typo in identifier name.

Co-authored-by: Håkan Sidenvall <[email protected]>
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.

3 participants