Ejemplo n.º 1
0
        public static StaticInspector CreateWindowStatic(Type type)
        {
            var window = new StaticInspector
            {
                TargetType = type,
                windowID   = WindowManager.NextWindowID(),
                m_rect     = WindowManager.GetNewWindowRect()
            };

            WindowManager.Windows.Add(window);

            window.Init();

            return(window);
        }
Ejemplo n.º 2
0
        public void Inspect(Type type)
        {
            if (type == null)
            {
                ExplorerCore.LogWarning("The provided type was null!");
                return;
            }

            foreach (var tab in m_currentInspectors.Where(x => x is StaticInspector))
            {
                if (ReferenceEquals(tab.Target as Type, type))
                {
                    SetInspectorTab(tab);
                    return;
                }
            }

            var inspector = new StaticInspector(type);

            m_currentInspectors.Add(inspector);
            SetInspectorTab(inspector);
        }