com.alicizax.unity/Editor/HybridCLR/HybridCLRSettingTab.cs

37 lines
1.1 KiB
C#
Raw Normal View History

2025-02-07 16:04:12 +08:00
using System;
using System.Collections.Generic;
using AlicizaX.Editor;
using Sirenix.OdinInspector;
using Sirenix.OdinInspector.Editor;
using Sirenix.Serialization;
using UnityEditor;
using UnityEngine;
namespace AlicizaX.Runtime
{
[DisplayName("热更设置")]
[Serializable]
internal sealed class HybridCLRSettingTab : GameFrameworkTabBase
{
[Required][InlineEditor(InlineEditorObjectFieldModes.CompletelyHidden)][DisableInPlayMode] [HideLabel]
public FrameworkHotUpdateSettings FrameworkHotUpdateSettings;
public HybridCLRSettingTab()
{
FrameworkHotUpdateSettings = ScriptableSingletonUtil.Get<FrameworkHotUpdateSettings>();
}
[Sirenix.OdinInspector.Button(ButtonSizes.Large)]
protected void RefreshAssembly()
{
SyncAssemblyContent.RefreshAssembly();
}
protected internal override void Save()
{
base.Save();
EditorUtility.SetDirty(FrameworkHotUpdateSettings);
AssetDatabase.SaveAssets();
}
}
}