1
0
mirror of synced 2024-11-28 08:00:50 +01:00
WACVR/Assets/uWindowCapture/Editor/UwcIconTextureEditor.cs

24 lines
564 B
C#
Raw Normal View History

2022-05-16 23:38:40 +02:00
using UnityEngine;
using UnityEditor;
namespace uWindowCapture
{
[CustomEditor(typeof(UwcIconTexture))]
public class UwcIconTextureEditor : Editor
{
UwcIconTexture texture
{
get { return target as UwcIconTexture; }
}
public override void OnInspectorGUI()
{
var windowTexture = (UwcWindowTexture)EditorGUILayout.ObjectField("Window Texture", texture.windowTexture, typeof(UwcWindowTexture), true);
if (texture.windowTexture != windowTexture) {
texture.windowTexture = windowTexture;
}
}
}
}