22 lines
556 B
C#
22 lines
556 B
C#
#if UNITY_2018_3_OR_NEWER
|
|
using UnityEditor.Experimental.SceneManagement;
|
|
#endif
|
|
using UnityEditor.SceneManagement;
|
|
|
|
|
|
namespace Coffee.UIExtensions.Editors
|
|
{
|
|
public static class Utils
|
|
{
|
|
public static void MarkPrefabDirty ()
|
|
{
|
|
#if UNITY_2018_3_OR_NEWER
|
|
var prefabStage = PrefabStageUtility.GetCurrentPrefabStage ();
|
|
if (prefabStage != null)
|
|
{
|
|
EditorSceneManager.MarkSceneDirty (prefabStage.scene);
|
|
}
|
|
#endif
|
|
}
|
|
}
|
|
} |