Exemple #1
0
        private void OpenComponentEditor(ComponentWrapper comp)
        {
            switch (comp.ComponentType)
            {
            case ComponentTypeWrapper.Library:
                if (PK.Wrapper.Solution != null)
                {
                    LibraryWrapper LW = PK.Wrapper.FindLibrary(comp);
                    if ((LW != null) && (!PK.Wrapper.Solution.IsReference(LW)))
                    {
                        mSolutionExplorer.Show(dockPanel1);
                        mSolutionExplorer.SetSelectedComponent(comp);
                    }
                    else
                    {
                        mLibrariesExplorer.Show(dockPanel1);
                        mLibrariesExplorer.SetSelectedComponent(comp);
                    }
                }
                else
                {
                    mLibrariesExplorer.Show(dockPanel1);
                    mLibrariesExplorer.SetSelectedComponent(comp);
                }
                break;

            case ComponentTypeWrapper.Feature:
                mFeaturesExplorer.Show(dockPanel1);
                mFeaturesExplorer.SetSelectedComponent(comp);
                break;

            case ComponentTypeWrapper.LibraryCategory:
                mLibraryCategoriesExplorer.Show(dockPanel1);
                mLibraryCategoriesExplorer.SetSelectedComponent(comp);
                break;

            case ComponentTypeWrapper.MFAssembly:
                mAssembliesExplorer.Show(dockPanel1);
                mAssembliesExplorer.SetSelectedComponent(comp);
                break;

            case ComponentTypeWrapper.MFSolution:
            case ComponentTypeWrapper.Processor:
            case ComponentTypeWrapper.OperatingSystem:
            case ComponentTypeWrapper.BuildTool:
            case ComponentTypeWrapper.ISA:
            case ComponentTypeWrapper.BuildParameter:
            case ComponentTypeWrapper.Unknown:
            default:
                //mEditorsController.ShowEditor(e.Object);
                break;
            }
        }