private static IEnumerable <Type> GetDefaultPaneTypes() { const string k_PaneTypesSectionName = "pane_types"; if (!ModeService.HasSection(ModeService.currentIndex, k_PaneTypesSectionName)) { return(k_PaneTypes); } return(GetCurrentModePaneTypes(k_PaneTypesSectionName)); }
private static IEnumerable <Type> GetDefaultPaneTypes() { const string k_PaneTypesSectionName = "pane_types"; if (!ModeService.HasSection(ModeService.currentIndex, k_PaneTypesSectionName)) { return(k_PaneTypes); } var modePaneTypes = ModeService.GetModeDataSectionList <string>(ModeService.currentIndex, k_PaneTypesSectionName).ToList(); return(TypeCache.GetTypesDerivedFrom <EditorWindow>().Where(t => modePaneTypes.Any(mpt => t.Name.EndsWith(mpt))).ToArray()); }
protected Type[] GetPaneTypes() { const string k_PaneTypesSectionName = "pane_types"; if (!ModeService.HasSection(ModeService.currentIndex, k_PaneTypesSectionName)) { return new[] { typeof(SceneView), typeof(GameView), typeof(InspectorWindow), typeof(SceneHierarchyWindow), typeof(ProjectBrowser), typeof(ProfilerWindow), typeof(AnimationWindow) } } ; var modePaneTypes = ModeService.GetModeDataSectionList <string>(ModeService.currentIndex, k_PaneTypesSectionName).ToArray(); return(EditorAssemblies.SubclassesOf(typeof(EditorWindow)).Where(t => modePaneTypes.Any(mpt => t.Name.EndsWith(mpt))).ToArray()); }