Ejemplo n.º 1
0
        public override void OnInspectorAbort(MightyDrawer drawer)
        {
            if (!MightyEditorUtilities.HasEditorChanged() || drawer == null)
            {
                return;
            }

            drawer.ApplyAutoValues();
            drawer.RefreshAllDrawers();
        }
Ejemplo n.º 2
0
        public override void OnInspectorAbort(MightyDrawer drawer)
        {
            if (MightyEditorUtilities.HasEditorChanged() && drawer != null)
            {
                drawer.ApplyAutoValues();
                drawer.RefreshAllDrawers();
            }

            GUILayout.BeginVertical();
        }
Ejemplo n.º 3
0
        protected void InspectorGUI()
        {
            if (m_drawer == null && !Enable() || !m_drawer.HasMightyMembers)
            {
                base.OnInspectorGUI();
                return;
            }

            m_drawer.BeginOnGUI();
            m_drawer.ManageMembers(out var valueChanged);

            if (valueChanged)
            {
                serializedObject.ManageValueChanged();
                m_drawer.ApplyAutoValues();
                m_drawer.RefreshAllDrawers();
                serializedObject.ManageValueChanged();
            }

            m_drawer.EndOnGUI();
        }