using UnityEngine;
using UnityEditor;
using System;

namespace mgaia.Utils
{
    /// <summary>
    /// Editor do behaviour de window transform
    /// </summary>
    /// <owner>Victor</owner>
    [CustomEditor(typeof(WindowTransform))]
    public class WindowTransformCustomEditor : UnityEditor.Editor
    {
        /// <summary>
        /// Desenha o editor customizado
        /// </summary>
        public override void OnInspectorGUI()
        {
            DrawDefaultInspector();

            if (GUILayout.Button("Get current coordinates"))
            {
                WindowTransform windowTransform = (WindowTransform)target;
                windowTransform.CalculateCurrentWindowPosition();
            }
        }
    }
}