UnityEditor.AvatarSubEditor.OnDestroy C# (CSharp) Method

OnDestroy() public method

public OnDestroy ( ) : void
return void
        public virtual void OnDestroy()
        {
            if (this.HasModified())
            {
                AssetImporter atPath = AssetImporter.GetAtPath(AssetDatabase.GetAssetPath(this.avatarAsset));
                if (atPath != null)
                {
                    if (EditorUtility.DisplayDialog("Unapplied import settings", "Unapplied import settings for '" + atPath.assetPath + "'", "Apply", "Revert"))
                    {
                        this.ApplyAndImport();
                    }
                    else
                    {
                        this.ResetValues();
                    }
                }
            }
        }