示例#1
0
 void OnDestroy()
 {
     if (s_instane == this)
     {
         s_instane = null;
     }
 }
示例#2
0
        static void Open()
        {
            if (s_instane)
            {
                return;
            }

            s_instane = CreateInstance <DefineSymbolEditorWindow>();
            s_instane.ShowUtility();
        }
示例#3
0
        //------------------------------------------------------
        // unity system function
        //------------------------------------------------------

        void OnEnable()
        {
            s_instane = this;

            titleContent = new GUIContent("DefineSymbol Editor");
            minSize      = new Vector2(570f, 380f);

            m_platforms = Array.ConvertAll(kTargets, i => new DefineSymbolPlatformData(i));
            m_current   = Array.Find(m_platforms, i => i.target == EditorUserBuildSettings.selectedBuildTargetGroup) ?? m_platforms[0];

            m_data    = DefineSymbolData.Load();
            m_context = new DefineSymbolContext(m_data.context);

            InitGUI();
            UpdatePresetLabels();
            SetSymbolMode();
        }