Skip to content

Commit 3660631

Browse files
jimonDmytro Ivanov
andauthored
FIX: Fixed behavior field repaint when switching input actions (#1580)
Co-authored-by: Dmytro Ivanov <dmytro@unity3d.com>
1 parent 0c2d01a commit 3660631

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

Packages/com.unity.inputsystem/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ however, it has to be formatted properly to pass verification tests.
1515
- Fix for mitigating symptoms reported in ([case UUM-10774](https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-10774) effectively avoiding reenabling mouse, pen or touch devices in `InputSystemPlugin.OnDestroy()` if currently quitting the editor. The fix avoids editor crashing if closed when Simulator Window is open. Note that the actual issue needs a separate fix in Unity and this package fix is only to avoid running into the issue.
1616
- Fixed an issue where Input Action name would not display correctly in Inspector if serialized as `[SerializedProperty]` within a class not derived from `MonoBehavior` ([case ISXB-124](https://issuetracker.unity3d.com/product/unity/issues/guid/ISXB-124).
1717
- Fix an issue where users could end up with the wrong device assignments when using the InputUser API directly and removing a user ([case ISXB-274](https://issuetracker.unity3d.com/product/unity/issues/guid/ISXB-231)).
18+
- Fixed an issue where PlayerInput behavior description was not updated when changing action assset ([case ISXB-286](https://issuetracker.unity3d.com/product/unity/issues/guid/ISXB-286)).
1819

1920
### Changed
2021
- Improved performance of HID descriptor parsing by moving json parsing to a simple custom predicitve parser instead of relying on Unity's json parsing. This should improve domain reload times when there are many HID devices connected to a machine.

Packages/com.unity.inputsystem/InputSystem/Plugins/PlayerInput/PlayerInputEditor.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,13 @@ public override void OnInspectorGUI()
7373
// Action config section.
7474
EditorGUI.BeginChangeCheck();
7575
EditorGUILayout.PropertyField(m_ActionsProperty);
76+
var actionsWereChanged = false;
7677
if (EditorGUI.EndChangeCheck() || !m_ActionAssetInitialized)
78+
{
7779
OnActionAssetChange();
80+
actionsWereChanged = true;
81+
}
82+
7883
++EditorGUI.indentLevel;
7984
if (m_ControlSchemeOptions != null && m_ControlSchemeOptions.Length > 1) // Don't show if <Any> is the only option.
8085
{
@@ -162,7 +167,7 @@ public override void OnInspectorGUI()
162167
// Notifications/event section.
163168
EditorGUI.BeginChangeCheck();
164169
EditorGUILayout.PropertyField(m_NotificationBehaviorProperty, m_NotificationBehaviorText);
165-
if (EditorGUI.EndChangeCheck() || !m_NotificationBehaviorInitialized)
170+
if (EditorGUI.EndChangeCheck() || actionsWereChanged || !m_NotificationBehaviorInitialized)
166171
OnNotificationBehaviorChange();
167172
switch ((PlayerNotifications)m_NotificationBehaviorProperty.intValue)
168173
{

0 commit comments

Comments
 (0)