Exemplo n.º 1
0
        public BHAVEditor OpenEditor(BHAV bhav, GameObject srcobj)
        {
            if (bhav == null)
            {
                return(null);
            }
            BHAVEditor window;

            if (Editors.ContainsKey(bhav))
            {
                window = Editors[bhav];
                var form = (Form)window;
                if (form.WindowState == FormWindowState.Minimized)
                {
                    form.WindowState = FormWindowState.Normal;
                }
                window.Activate();
                return(window);
            }

            window = new BHAVEditor(bhav, new EditorComponent.EditorScope(srcobj, bhav));
            window.Show();
            window.Activate();
            Editors.Add(bhav, window);
            return(window);
        }
Exemplo n.º 2
0
        public BHAVEditor OpenEditor(BHAV bhav, GameObject srcobj)
        {
            BHAVEditor window;
            if (Editors.ContainsKey(bhav))
            {
                window = Editors[bhav];
                var form = (Form)window;
                if (form.WindowState == FormWindowState.Minimized) form.WindowState = FormWindowState.Normal;
                window.Activate();
                return window;
            }

            window = new BHAVEditor(bhav, new EditorComponent.EditorScope(srcobj, bhav));
            window.Show();
            window.Activate();
            Editors.Add(bhav, window);
            return window;
        }
Exemplo n.º 3
0
        public BHAVEditor OpenTracer(VM vm, VMEntity entity)
        {
            BHAVEditor window;
            if (Tracers.ContainsKey(entity))
            {
                window = Tracers[entity];
                window.UpdateDebugger();
                var form = (Form)window;
                if (form.WindowState == FormWindowState.Minimized) form.WindowState = FormWindowState.Normal;
                window.Activate();
                return window;
            }

            window = new BHAVEditor(vm, entity);
            window.Show();
            window.Activate();
            Tracers.Add(entity, window);
            return window;
        }
Exemplo n.º 4
0
        public BHAVEditor OpenTracer(VM vm, VMEntity entity)
        {
            BHAVEditor window;

            if (Tracers.ContainsKey(entity))
            {
                window = Tracers[entity];
                window.UpdateDebugger();
                var form = (Form)window;
                if (form.WindowState == FormWindowState.Minimized)
                {
                    form.WindowState = FormWindowState.Normal;
                }
                window.Activate();
                return(window);
            }

            window = new BHAVEditor(vm, entity);
            window.Show();
            window.Activate();
            Tracers.Add(entity, window);
            return(window);
        }