From cfca0391985b05032d4a63498b90e88894bef2b7 Mon Sep 17 00:00:00 2001 From: Martin Sternevald Date: Tue, 17 Dec 2024 17:50:41 +0100 Subject: [PATCH 1/2] Fix location of link xml file. We need a location that is persistent and not cleaned when exiting Unity Editor (ISX-2140) --- .../Editor/BuildPipeline/LinkFileGenerator.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/BuildPipeline/LinkFileGenerator.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/BuildPipeline/LinkFileGenerator.cs index 66eaeb872d..eb5afba946 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/BuildPipeline/LinkFileGenerator.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/BuildPipeline/LinkFileGenerator.cs @@ -77,9 +77,12 @@ public string GenerateAdditionalLinkXmlFile(BuildReport report, UnityLinkerBuild sb.AppendLine(""); - var filePathName = Path.Combine(Application.dataPath, "..", "Temp", "InputSystemLink.xml"); - File.WriteAllText(filePathName, sb.ToString()); - return filePathName; + var linkXmlDirectory = Path.Combine(Application.dataPath, "..", "Library", "InputSystem"); + var linkXmlFile = Path.Combine(linkXmlDirectory, $"{data.target}Link.xml"); + + Directory.CreateDirectory(linkXmlDirectory); + File.WriteAllText(linkXmlFile, sb.ToString()); + return linkXmlFile; } static bool IsTypeUsedViaReflectionByInputSystem(Type type) From 6a1b45596da95b9c5c2d2f15ebd75f24ca27a2a3 Mon Sep 17 00:00:00 2001 From: Martin Sternevald Date: Wed, 18 Dec 2024 13:19:22 +0100 Subject: [PATCH 2/2] Added changelog entry --- Packages/com.unity.inputsystem/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Packages/com.unity.inputsystem/CHANGELOG.md b/Packages/com.unity.inputsystem/CHANGELOG.md index 2a36143974..4283e02128 100644 --- a/Packages/com.unity.inputsystem/CHANGELOG.md +++ b/Packages/com.unity.inputsystem/CHANGELOG.md @@ -36,6 +36,7 @@ however, it has to be formatted properly to pass verification tests. - Fixed Action properties edition in the UI Toolkit version of the Input Actions Asset editor. [ISXB-1277](https://issuetracker.unity3d.com/product/unity/issues/guid/ISXB-1277) ### Changed +- Changed location of the link xml file (code stripping rules), from a temporary directory to the project Library folder (ISX-2140). - Added back the InputManager to InputSystem project-wide asset migration code with performance improvement (ISX-2086). - Changed `OnScreenControl` to automaticaly switch, in Single Player with autoswitch enabled, to the target device control scheme when the first component is enabled to prevent bad interactions when it start. - Changed paremeter `overrideModifiersNeedToBePressedFirst` to obsolete for `ButtonWithOneModifier`, `ButtonWithTwoModifiers`, `OneModifierComposite` and `TwoModifiersComposite` in favour the new `modifiersOrder` parameter which is more explicit.