33 lines
781 B
C#
33 lines
781 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEditor;
|
|
using UnityEngine;
|
|
using UnityEngine.UIElements;
|
|
|
|
namespace BITKit.SceneManagement.Editor
|
|
{
|
|
public class SceneServiceEditorWindow : EditorWindow
|
|
{
|
|
[MenuItem("Tools/Scenes/SceneService")]
|
|
public static void Open()
|
|
{
|
|
GetWindow<SceneServiceEditorWindow>("SceneService").Show();
|
|
}
|
|
|
|
private Toggle allowInitializeToggle;
|
|
|
|
private void OnEnable()
|
|
{
|
|
allowInitializeToggle = rootVisualElement.Create<Toggle>();
|
|
allowInitializeToggle.label = "Allow Initialize";
|
|
allowInitializeToggle.SetValueWithoutNotify(SceneService.AllowInitialize);
|
|
allowInitializeToggle.RegisterValueChangedCallback(evt =>
|
|
{
|
|
SceneService.AllowInitialize = evt.newValue;
|
|
});
|
|
}
|
|
}
|
|
|
|
}
|