From fac7d908801432a9e1301f8762c57e589c58ed9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Freire?= Date: Thu, 25 May 2023 17:29:28 +0200 Subject: [PATCH 1/3] Add 2022.1 to CI testing --- .yamato/config.metadata | 1 + 1 file changed, 1 insertion(+) diff --git a/.yamato/config.metadata b/.yamato/config.metadata index c5c629ce60..440fe68526 100644 --- a/.yamato/config.metadata +++ b/.yamato/config.metadata @@ -2,6 +2,7 @@ editors: - version: 2020.3 disable_tvos_run: true - version: 2021.3 + - version: 2022.1 - version: 2022.2 - version: 2023.1 - version: trunk From 83aacdab2b089f810103737cfca50e42ceff067b Mon Sep 17 00:00:00 2001 From: James McGill Date: Thu, 25 May 2023 15:14:51 +0200 Subject: [PATCH 2/3] fix compilation errors on 2022.1 --- Assets/Samples/CustomComposite/CustomComposite.cs | 2 +- Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs | 2 +- Assets/Tests/InputSystem.Editor/SelectorsTests.cs | 2 +- Assets/Tests/InputSystem.Editor/TestData.cs | 2 +- Assets/Tests/InputSystem.Editor/TestDataGenerators.cs | 2 +- .../InputSystem/Actions/Composites/Vector2Composite.cs | 2 +- .../InputSystem/Actions/Composites/Vector3Composite.cs | 2 +- .../InputSystem/Actions/InputControlScheme.cs | 2 +- .../InputSystem/Actions/Interactions/HoldInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/MultiTapInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/PressInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/SlowTapInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/TapInteraction.cs | 2 +- .../Controls/Processors/AxisDeadzoneProcessor.cs | 2 +- .../Controls/Processors/StickDeadzoneProcessor.cs | 2 +- .../Editor/AssetEditor/InputActionEditorWindow.cs | 2 +- .../InputSystem/Editor/AssetEditor/ParameterListView.cs | 2 +- .../InputSystem/Editor/InputParameterEditor.cs | 6 +++--- .../InputSystem/Editor/UITKAssetEditor/Commands/Commands.cs | 2 +- .../UITKAssetEditor/Commands/ControlSchemeCommands.cs | 2 +- .../UITKAssetEditor/InputActionsEditorSettingsProvider.cs | 2 +- .../Editor/UITKAssetEditor/InputActionsEditorState.cs | 2 +- .../Editor/UITKAssetEditor/InputActionsEditorWindow.cs | 2 +- .../Editor/UITKAssetEditor/SerializedInputAction.cs | 2 +- .../Editor/UITKAssetEditor/SerializedInputBinding.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/StateContainer.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionMapsView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionPropertiesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionsTreeView.cs | 2 +- .../Editor/UITKAssetEditor/Views/BindingPropertiesView.cs | 2 +- .../UITKAssetEditor/Views/CompositeBindingPropertiesView.cs | 2 +- .../Views/CompositePartBindingPropertiesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ControlSchemesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/InputActionsEditorView.cs | 2 +- .../UITKAssetEditor/Views/InputActionsTreeViewItem.cs | 2 +- .../UITKAssetEditor/Views/NameAndParametersListView.cs | 2 +- .../Editor/UITKAssetEditor/Views/PropertiesView.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/Views/Selectors.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/Views/ViewBase.cs | 2 +- .../Editor/UITKAssetEditor/Views/VisualElementExtensions.cs | 2 +- .../com.unity.inputsystem/InputSystem/InputFeatureNames.cs | 2 +- 41 files changed, 43 insertions(+), 43 deletions(-) diff --git a/Assets/Samples/CustomComposite/CustomComposite.cs b/Assets/Samples/CustomComposite/CustomComposite.cs index aaeadb81b3..e9730dd05a 100644 --- a/Assets/Samples/CustomComposite/CustomComposite.cs +++ b/Assets/Samples/CustomComposite/CustomComposite.cs @@ -177,7 +177,7 @@ public override void OnGUI() target.scaleFactor = EditorGUILayout.Slider(m_ScaleFactorLabel, currentValue, 0, 2); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var slider = new Slider(m_ScaleFactorLabel.text, 0, 2) diff --git a/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs b/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs index b3bdc01e24..47b233da96 100644 --- a/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs +++ b/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER using NUnit.Framework; using UnityEngine.InputSystem; using UnityEngine.InputSystem.Editor; diff --git a/Assets/Tests/InputSystem.Editor/SelectorsTests.cs b/Assets/Tests/InputSystem.Editor/SelectorsTests.cs index 006feffb7a..826a5e63ca 100644 --- a/Assets/Tests/InputSystem.Editor/SelectorsTests.cs +++ b/Assets/Tests/InputSystem.Editor/SelectorsTests.cs @@ -1,6 +1,6 @@ // UITK TreeView is not supported in earlier versions // Therefore the UITK version of the InputActionAsset Editor is not available on earlier Editor versions either. -#if UNITY_EDITOR && UNITY_2022_1_OR_NEWER +#if UNITY_EDITOR && UNITY_2022_2_OR_NEWER using System.Linq; using NUnit.Framework; using UnityEngine; diff --git a/Assets/Tests/InputSystem.Editor/TestData.cs b/Assets/Tests/InputSystem.Editor/TestData.cs index b4c26251da..f133c862aa 100644 --- a/Assets/Tests/InputSystem.Editor/TestData.cs +++ b/Assets/Tests/InputSystem.Editor/TestData.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER using System.Collections.Generic; using UnityEditor; using UnityEngine; diff --git a/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs b/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs index a412ffa319..6b674bac87 100644 --- a/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs +++ b/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER using System.Collections.Generic; using UnityEngine.InputSystem; diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs index 3423619e9f..efddd12824 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs @@ -204,7 +204,7 @@ public override void OnGUI() target.mode = (Vector2Composite.Mode)EditorGUILayout.EnumPopup(m_ModeLabel, target.mode); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var modeField = new EnumField("Mode", target.mode) diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs index f86f9db96e..5e0adacd80 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs @@ -177,7 +177,7 @@ public override void OnGUI() target.mode = (Vector2Composite.Mode)EditorGUILayout.EnumPopup(m_ModeLabel, target.mode); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var modeField = new EnumField("Mode", target.mode) diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs index ea031654d2..c6bc4af5e4 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs @@ -112,7 +112,7 @@ public InputControlScheme(string name, IEnumerable devices = } } - #if UNITY_EDITOR && UNITY_2022_1_OR_NEWER + #if UNITY_EDITOR && UNITY_2022_2_OR_NEWER internal InputControlScheme(SerializedProperty sp) { var requirements = new List(); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs index f2db4bba3e..19e24f6990 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs @@ -128,7 +128,7 @@ public override void OnGUI() m_DurationSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_PressPointSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs index 8a4990b630..e1373fed9f 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs @@ -202,7 +202,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var tapCountField = new IntegerField(m_TapCountLabel.text) { value = target.tapCount }; diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs index 6b29ab1e4a..cddcac603a 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs @@ -218,7 +218,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { root.Add(new HelpBox(s_HelpBoxText.text, HelpBoxMessageType.None)); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs index 0aa756713a..597b610d36 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs @@ -92,7 +92,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_DurationSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs index 39a5bbe4d4..c6ac415127 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs @@ -106,7 +106,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_DurationSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs index 1e2f34dc5c..06e652bbc0 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs @@ -97,7 +97,7 @@ public override void OnGUI() m_MaxSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_MinSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs index 10cc7f35d9..e7bd3dee3e 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs @@ -86,7 +86,7 @@ public override void OnGUI() m_MaxSetting.OnGUI(); } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_MinSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs index f1cae1d2a3..a8f7783d89 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs @@ -37,7 +37,7 @@ internal class InputActionEditorWindow : EditorWindow, IDisposable [OnOpenAsset] public static bool OnOpenAsset(int instanceId, int line) { -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER if (InputSystem.settings.IsFeatureEnabled(InputFeatureNames.kUseUIToolkitEditor)) return false; #endif diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs index f780dcd690..aecf411f66 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs @@ -247,7 +247,7 @@ public void Clear() m_ParameterEditor = null; } -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER public void OnDrawVisualElements(VisualElement root) { if (m_ParameterEditor != null) diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs index b47017af64..e2d96b07c5 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs @@ -32,7 +32,7 @@ public abstract class InputParameterEditor /// public abstract void OnGUI(); -#if UNITY_2022_1_OR_NEWER +#if UNITY_2022_2_OR_NEWER /// /// Add visual elements for this parameter editor to a root VisualElement. /// @@ -212,7 +212,7 @@ public void Initialize(string label, string tooltip, string defaultName, Func Date: Fri, 26 May 2023 17:30:43 +0200 Subject: [PATCH 3/3] RELEASE: 1.6.1 (#1683) * ensure UITK asset editor code is guarded by compiler defines * RELEASE: 1.6.1 * bump version on test assets --- Assets/Samples/CustomComposite/CustomComposite.cs | 2 +- Assets/Samples/InGameHints/InGameHintsActions.cs | 2 +- Assets/Samples/SimpleDemo/SimpleControls.cs | 2 +- Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs | 2 +- Assets/Tests/InputSystem.Editor/SelectorsTests.cs | 2 +- Assets/Tests/InputSystem.Editor/TestData.cs | 2 +- Assets/Tests/InputSystem.Editor/TestDataGenerators.cs | 2 +- Assets/Tests/InputSystem/InputActionCodeGeneratorActions.cs | 2 +- Packages/com.unity.inputsystem/CHANGELOG.md | 5 +++++ .../InputSystem/Actions/Composites/Vector2Composite.cs | 2 +- .../InputSystem/Actions/Composites/Vector3Composite.cs | 2 +- .../InputSystem/Actions/InputControlScheme.cs | 2 +- .../InputSystem/Actions/Interactions/HoldInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/MultiTapInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/PressInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/SlowTapInteraction.cs | 2 +- .../InputSystem/Actions/Interactions/TapInteraction.cs | 2 +- Packages/com.unity.inputsystem/InputSystem/AssemblyInfo.cs | 2 +- .../Controls/Processors/AxisDeadzoneProcessor.cs | 2 +- .../Controls/Processors/StickDeadzoneProcessor.cs | 2 +- .../InputSystem/Devices/Precompiled/FastKeyboard.cs | 2 +- .../InputSystem/Devices/Precompiled/FastMouse.cs | 2 +- .../InputSystem/Devices/Precompiled/FastTouchscreen.cs | 2 +- .../Editor/AssetEditor/InputActionEditorWindow.cs | 2 +- .../InputSystem/Editor/AssetEditor/ParameterListView.cs | 2 +- .../InputSystem/Editor/InputParameterEditor.cs | 6 +++--- .../InputSystem/Editor/UITKAssetEditor/Commands/Commands.cs | 2 +- .../UITKAssetEditor/Commands/ControlSchemeCommands.cs | 2 +- .../UITKAssetEditor/InputActionsEditorSettingsProvider.cs | 2 +- .../Editor/UITKAssetEditor/InputActionsEditorState.cs | 2 +- .../Editor/UITKAssetEditor/InputActionsEditorWindow.cs | 2 +- .../Editor/UITKAssetEditor/SerializedInputAction.cs | 2 +- .../Editor/UITKAssetEditor/SerializedInputBinding.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/StateContainer.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionMapsView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionPropertiesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ActionsTreeView.cs | 2 +- .../Editor/UITKAssetEditor/Views/BindingPropertiesView.cs | 2 +- .../UITKAssetEditor/Views/CompositeBindingPropertiesView.cs | 2 +- .../Views/CompositePartBindingPropertiesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/ControlSchemesView.cs | 2 +- .../Editor/UITKAssetEditor/Views/InputActionsEditorView.cs | 2 +- .../UITKAssetEditor/Views/InputActionsTreeViewItem.cs | 2 +- .../UITKAssetEditor/Views/NameAndParametersListView.cs | 2 +- .../Editor/UITKAssetEditor/Views/PropertiesView.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/Views/Selectors.cs | 2 +- .../InputSystem/Editor/UITKAssetEditor/Views/ViewBase.cs | 2 +- .../Editor/UITKAssetEditor/Views/VisualElementExtensions.cs | 2 +- .../com.unity.inputsystem/InputSystem/InputFeatureNames.cs | 2 +- .../com.unity.inputsystem/Tests/TestFixture/AssemblyInfo.cs | 2 +- Packages/com.unity.inputsystem/ValidationExceptions.json | 2 +- Packages/com.unity.inputsystem/package.json | 2 +- 52 files changed, 58 insertions(+), 53 deletions(-) diff --git a/Assets/Samples/CustomComposite/CustomComposite.cs b/Assets/Samples/CustomComposite/CustomComposite.cs index e9730dd05a..6c26fb1db1 100644 --- a/Assets/Samples/CustomComposite/CustomComposite.cs +++ b/Assets/Samples/CustomComposite/CustomComposite.cs @@ -177,7 +177,7 @@ public override void OnGUI() target.scaleFactor = EditorGUILayout.Slider(m_ScaleFactorLabel, currentValue, 0, 2); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var slider = new Slider(m_ScaleFactorLabel.text, 0, 2) diff --git a/Assets/Samples/InGameHints/InGameHintsActions.cs b/Assets/Samples/InGameHints/InGameHintsActions.cs index c2ba3e5877..b0b46581f1 100644 --- a/Assets/Samples/InGameHints/InGameHintsActions.cs +++ b/Assets/Samples/InGameHints/InGameHintsActions.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputActionCodeGenerator -// version 1.6.0 +// version 1.6.1 // from Assets/Samples/InGameHints/InGameHintsActions.inputactions // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Assets/Samples/SimpleDemo/SimpleControls.cs b/Assets/Samples/SimpleDemo/SimpleControls.cs index 71bc1013ea..0a83630ae4 100644 --- a/Assets/Samples/SimpleDemo/SimpleControls.cs +++ b/Assets/Samples/SimpleDemo/SimpleControls.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputActionCodeGenerator -// version 1.6.0 +// version 1.6.1 // from Assets/Samples/SimpleDemo/SimpleControls.inputactions // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs b/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs index 47b233da96..25d9905dac 100644 --- a/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs +++ b/Assets/Tests/InputSystem.Editor/ControlSchemeEditorTests.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR using NUnit.Framework; using UnityEngine.InputSystem; using UnityEngine.InputSystem.Editor; diff --git a/Assets/Tests/InputSystem.Editor/SelectorsTests.cs b/Assets/Tests/InputSystem.Editor/SelectorsTests.cs index 826a5e63ca..d69dc0e169 100644 --- a/Assets/Tests/InputSystem.Editor/SelectorsTests.cs +++ b/Assets/Tests/InputSystem.Editor/SelectorsTests.cs @@ -1,6 +1,6 @@ // UITK TreeView is not supported in earlier versions // Therefore the UITK version of the InputActionAsset Editor is not available on earlier Editor versions either. -#if UNITY_EDITOR && UNITY_2022_2_OR_NEWER +#if UNITY_EDITOR && UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR using System.Linq; using NUnit.Framework; using UnityEngine; diff --git a/Assets/Tests/InputSystem.Editor/TestData.cs b/Assets/Tests/InputSystem.Editor/TestData.cs index f133c862aa..d1a987dc4f 100644 --- a/Assets/Tests/InputSystem.Editor/TestData.cs +++ b/Assets/Tests/InputSystem.Editor/TestData.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR using System.Collections.Generic; using UnityEditor; using UnityEngine; diff --git a/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs b/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs index 6b674bac87..1099aea180 100644 --- a/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs +++ b/Assets/Tests/InputSystem.Editor/TestDataGenerators.cs @@ -1,4 +1,4 @@ -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR using System.Collections.Generic; using UnityEngine.InputSystem; diff --git a/Assets/Tests/InputSystem/InputActionCodeGeneratorActions.cs b/Assets/Tests/InputSystem/InputActionCodeGeneratorActions.cs index c59f66a3bb..e247ed2873 100644 --- a/Assets/Tests/InputSystem/InputActionCodeGeneratorActions.cs +++ b/Assets/Tests/InputSystem/InputActionCodeGeneratorActions.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputActionCodeGenerator -// version 1.6.0 +// version 1.6.1 // from Assets/Tests/InputSystem/InputActionCodeGeneratorActions.inputactions // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Packages/com.unity.inputsystem/CHANGELOG.md b/Packages/com.unity.inputsystem/CHANGELOG.md index 205dd23de2..f963ed950b 100644 --- a/Packages/com.unity.inputsystem/CHANGELOG.md +++ b/Packages/com.unity.inputsystem/CHANGELOG.md @@ -8,6 +8,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. Due to package verification, the latest version below is the unpublished version and the date is meaningless. however, it has to be formatted properly to pass verification tests. +## [1.6.1] - 2023-05-26 + +### Fixed +- Fixed issue with compiling in Unity 2022.1 and with XR Toolkit by guarding the experimental UITK Asset Editor code completely. + ## [1.6.0] - 2023-05-25 ### Added diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs index efddd12824..1aa572b8ef 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector2Composite.cs @@ -204,7 +204,7 @@ public override void OnGUI() target.mode = (Vector2Composite.Mode)EditorGUILayout.EnumPopup(m_ModeLabel, target.mode); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var modeField = new EnumField("Mode", target.mode) diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs index 5e0adacd80..77b7cc5950 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Composites/Vector3Composite.cs @@ -177,7 +177,7 @@ public override void OnGUI() target.mode = (Vector2Composite.Mode)EditorGUILayout.EnumPopup(m_ModeLabel, target.mode); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var modeField = new EnumField("Mode", target.mode) diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs index c6bc4af5e4..070a25721e 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/InputControlScheme.cs @@ -112,7 +112,7 @@ public InputControlScheme(string name, IEnumerable devices = } } - #if UNITY_EDITOR && UNITY_2022_2_OR_NEWER + #if UNITY_EDITOR && UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR internal InputControlScheme(SerializedProperty sp) { var requirements = new List(); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs index 19e24f6990..4ef657aee7 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/HoldInteraction.cs @@ -128,7 +128,7 @@ public override void OnGUI() m_DurationSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_PressPointSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs index e1373fed9f..513c05de5b 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/MultiTapInteraction.cs @@ -202,7 +202,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { var tapCountField = new IntegerField(m_TapCountLabel.text) { value = target.tapCount }; diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs index cddcac603a..b9ad14634b 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/PressInteraction.cs @@ -218,7 +218,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { root.Add(new HelpBox(s_HelpBoxText.text, HelpBoxMessageType.None)); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs index 597b610d36..a800fedeaf 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/SlowTapInteraction.cs @@ -92,7 +92,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_DurationSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs index c6ac415127..6bc6b6fb12 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Actions/Interactions/TapInteraction.cs @@ -106,7 +106,7 @@ public override void OnGUI() m_PressPointSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_DurationSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/AssemblyInfo.cs b/Packages/com.unity.inputsystem/InputSystem/AssemblyInfo.cs index 9555a9fe45..07ba0ef78a 100644 --- a/Packages/com.unity.inputsystem/InputSystem/AssemblyInfo.cs +++ b/Packages/com.unity.inputsystem/InputSystem/AssemblyInfo.cs @@ -15,7 +15,7 @@ public static partial class InputSystem // Keep this in sync with "Packages/com.unity.inputsystem/package.json". // NOTE: Unfortunately, System.Version doesn't use semantic versioning so we can't include // "-preview" suffixes here. - internal const string kAssemblyVersion = "1.6.0"; + internal const string kAssemblyVersion = "1.6.1"; internal const string kDocUrl = "https://docs.unity3d.com/Packages/com.unity.inputsystem@1.6"; } } diff --git a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs index 06e652bbc0..4713b2e67a 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/AxisDeadzoneProcessor.cs @@ -97,7 +97,7 @@ public override void OnGUI() m_MaxSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_MinSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs index e7bd3dee3e..bcb4cf4d0b 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Controls/Processors/StickDeadzoneProcessor.cs @@ -86,7 +86,7 @@ public override void OnGUI() m_MaxSetting.OnGUI(); } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public override void OnDrawVisualElements(VisualElement root, Action onChangedCallback) { m_MinSetting.OnDrawVisualElements(root, onChangedCallback); diff --git a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastKeyboard.cs b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastKeyboard.cs index a2dc54c2b6..0a0ed6fdb9 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastKeyboard.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastKeyboard.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputLayoutCodeGenerator -// version 1.6.0 +// version 1.6.1 // from "Keyboard" layout // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastMouse.cs b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastMouse.cs index 5556767cfa..977b02532f 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastMouse.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastMouse.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputLayoutCodeGenerator -// version 1.6.0 +// version 1.6.1 // from "Mouse" layout // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastTouchscreen.cs b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastTouchscreen.cs index 4acaa7b73d..ab1b802c84 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastTouchscreen.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Devices/Precompiled/FastTouchscreen.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // // This code was auto-generated by com.unity.inputsystem:InputLayoutCodeGenerator -// version 1.6.0 +// version 1.6.1 // from "Touchscreen" layout // // Changes to this file may cause incorrect behavior and will be lost if diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs index a8f7783d89..068c5c1138 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/InputActionEditorWindow.cs @@ -37,7 +37,7 @@ internal class InputActionEditorWindow : EditorWindow, IDisposable [OnOpenAsset] public static bool OnOpenAsset(int instanceId, int line) { -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR if (InputSystem.settings.IsFeatureEnabled(InputFeatureNames.kUseUIToolkitEditor)) return false; #endif diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs index aecf411f66..0128b2881e 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/AssetEditor/ParameterListView.cs @@ -247,7 +247,7 @@ public void Clear() m_ParameterEditor = null; } -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR public void OnDrawVisualElements(VisualElement root) { if (m_ParameterEditor != null) diff --git a/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs b/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs index e2d96b07c5..aa9e36e934 100644 --- a/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs +++ b/Packages/com.unity.inputsystem/InputSystem/Editor/InputParameterEditor.cs @@ -32,7 +32,7 @@ public abstract class InputParameterEditor /// public abstract void OnGUI(); -#if UNITY_2022_2_OR_NEWER +#if UNITY_INPUT_SYSTEM_UI_TK_ASSET_EDITOR /// /// Add visual elements for this parameter editor to a root VisualElement. /// @@ -212,7 +212,7 @@ public void Initialize(string label, string tooltip, string defaultName, Func