mirror of https://github.com/tuyoogame/YooAsset
parent
9b0bebd981
commit
e674d5bf97
|
@ -6,6 +6,11 @@ using UnityEngine.U2D;
|
||||||
|
|
||||||
public static class UIPanelSettings
|
public static class UIPanelSettings
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 是否开启面板监测
|
||||||
|
/// </summary>
|
||||||
|
public static bool EnablePanelMonitor = false;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 面板文件夹GUID
|
/// 面板文件夹GUID
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -60,6 +65,9 @@ public class UIPanelMonitor : UnityEditor.Editor
|
||||||
|
|
||||||
static void OnPrefabSaving(GameObject go)
|
static void OnPrefabSaving(GameObject go)
|
||||||
{
|
{
|
||||||
|
if (UIPanelSettings.EnablePanelMonitor == false)
|
||||||
|
return;
|
||||||
|
|
||||||
UnityEditor.SceneManagement.PrefabStage stage = UnityEditor.SceneManagement.PrefabStageUtility.GetCurrentPrefabStage();
|
UnityEditor.SceneManagement.PrefabStage stage = UnityEditor.SceneManagement.PrefabStageUtility.GetCurrentPrefabStage();
|
||||||
if (stage != null)
|
if (stage != null)
|
||||||
{
|
{
|
||||||
|
@ -78,7 +86,7 @@ public class UIPanelMonitor : UnityEditor.Editor
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 刷新面板清单
|
/// 刷新面板清单
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static void RefreshPanelManifest(PanelManifest manifest)
|
private static void RefreshPanelManifest(PanelManifest manifest)
|
||||||
{
|
{
|
||||||
manifest.ReferencesAtlas.Clear();
|
manifest.ReferencesAtlas.Clear();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue