Skip to content

Commit 0b2ff4f

Browse files
committed
Rename MarkAsDirty to MarkAsDirtyInEditor for clarity in InputActionAsset and related classes
1 parent f5e38af commit 0b2ff4f

3 files changed

Lines changed: 7 additions & 7 deletions

File tree

Packages/com.unity.inputsystem/InputSystem/Runtime/Actions/InputActionAsset.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -891,7 +891,7 @@ IEnumerator IEnumerable.GetEnumerator()
891891
return GetEnumerator();
892892
}
893893

894-
internal void MarkAsDirty()
894+
internal void MarkAsDirtyInEditor()
895895
{
896896
#if UNITY_EDITOR
897897
s_OnMarkAsDirty?.Invoke(this);
@@ -915,7 +915,7 @@ internal void OnWantToChangeSetup()
915915

916916
internal void OnSetupChanged()
917917
{
918-
MarkAsDirty();
918+
MarkAsDirtyInEditor();
919919

920920
if (m_ActionMaps.LengthSafe() > 0)
921921
m_ActionMaps[0].OnSetupChanged();

Packages/com.unity.inputsystem/InputSystem/Runtime/Actions/InputActionMap.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1151,7 +1151,7 @@ internal void OnSetupChanged()
11511151
{
11521152
if (m_Asset != null)
11531153
{
1154-
m_Asset.MarkAsDirty();
1154+
m_Asset.MarkAsDirtyInEditor();
11551155
foreach (var map in m_Asset.actionMaps)
11561156
map.m_State = default;
11571157
}

Packages/com.unity.inputsystem/InputSystem/Runtime/Actions/InputActionSetupExtensions.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ private static int AddBindingInternal(InputActionMap map, InputBinding binding,
584584
// Make sure this asset is reloaded from disk when exiting play mode so it isn't inadvertently
585585
// changed between play sessions. Only applies when running in the editor.
586586
if (map.asset != null)
587-
map.asset.MarkAsDirty();
587+
map.asset.MarkAsDirtyInEditor();
588588

589589
// If we're looking at a singleton action, make sure m_Bindings is up to date just
590590
// in case the action gets serialized.
@@ -955,7 +955,7 @@ public static void Rename(this InputAction action, string newName)
955955
actionMap?.ClearActionLookupTable();
956956

957957
if (actionMap?.asset != null)
958-
actionMap?.asset.MarkAsDirty();
958+
actionMap?.asset.MarkAsDirtyInEditor();
959959

960960
// Update bindings.
961961
var bindings = action.GetOrCreateActionMap().m_Bindings;
@@ -992,7 +992,7 @@ public static void AddControlScheme(this InputActionAsset asset, InputControlSch
992992

993993
ArrayHelpers.Append(ref asset.m_ControlSchemes, controlScheme);
994994

995-
asset.MarkAsDirty();
995+
asset.MarkAsDirtyInEditor();
996996
}
997997

998998
/// <summary>
@@ -1063,7 +1063,7 @@ public static void RemoveControlScheme(this InputActionAsset asset, string name)
10631063
if (index != -1)
10641064
ArrayHelpers.EraseAt(ref asset.m_ControlSchemes, index);
10651065

1066-
asset.MarkAsDirty();
1066+
asset.MarkAsDirtyInEditor();
10671067
}
10681068

10691069
/// <summary>

0 commit comments

Comments
 (0)