Note inspector调整,Static Window可开关,Log可复制清空
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
@@ -6,6 +7,29 @@ namespace Ichni.Editor
|
||||
{
|
||||
public abstract class StaticWindow : MonoBehaviour
|
||||
{
|
||||
public EnableButtonGroup enableButtonGroup;
|
||||
|
||||
protected virtual void Start()
|
||||
{
|
||||
if (enableButtonGroup != null)
|
||||
{
|
||||
enableButtonGroup.enableButton.onClick.AddListener(EnableWindow);
|
||||
enableButtonGroup.disableButton.onClick.AddListener(DisableWindow);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void EnableWindow()
|
||||
{
|
||||
gameObject.SetActive(true);
|
||||
enableButtonGroup.disableButton.gameObject.SetActive(true);
|
||||
enableButtonGroup.enableButton.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
public virtual void DisableWindow()
|
||||
{
|
||||
gameObject.SetActive(false);
|
||||
enableButtonGroup.disableButton.gameObject.SetActive(false);
|
||||
enableButtonGroup.enableButton.gameObject.SetActive(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user