use of org.uberfire.workbench.model.impl.PartDefinitionImpl in project kie-wb-common by kiegroup.
the class LibraryPlaces method setupLibraryPerspective.
private void setupLibraryPerspective() {
OrganizationalUnit activeOu = projectContext.getActiveOrganizationalUnit().orElseThrow(() -> new IllegalStateException("Cannot setup library perspective without active space."));
PortablePreconditions.checkNotNull("libraryPerspective", libraryPerspective);
final PlaceRequest placeRequest = new DefaultPlaceRequest(LibraryPlaces.LIBRARY_SCREEN);
final PartDefinitionImpl part = new PartDefinitionImpl(placeRequest);
part.setSelectable(false);
if (!projectContext.getActiveWorkspaceProject().isPresent()) {
projectContextChangeEvent.fire(new WorkspaceProjectContextChangeEvent(activeOu));
}
closeLibraryPlaces();
placeManager.goTo(part, libraryPerspective.getRootPanel());
setupLibraryBreadCrumbsWithoutProject();
hideDocks();
}
use of org.uberfire.workbench.model.impl.PartDefinitionImpl in project kie-wb-common by kiegroup.
the class LibraryPlaces method goToSettings.
public void goToSettings() {
final DefaultPlaceRequest placeRequest = new DefaultPlaceRequest(PROJECT_SETTINGS);
final PartDefinitionImpl part = new PartDefinitionImpl(placeRequest);
part.setSelectable(false);
closeLibraryPlaces();
placeManager.goTo(part, libraryPerspective.getRootPanel());
}
use of org.uberfire.workbench.model.impl.PartDefinitionImpl in project kie-wb-common by kiegroup.
the class HomePerspective method getPerspective.
@Perspective
public PerspectiveDefinition getPerspective() {
final PerspectiveDefinition p = new PerspectiveDefinitionImpl(StaticWorkbenchPanelPresenter.class.getName());
p.setName(translationService.format(HomeConstants.HomePerspectiveName));
p.getRoot().addPart(new PartDefinitionImpl(new DefaultPlaceRequest("org.kie.workbench.common.screens.home.client.HomePresenter")));
return p;
}
use of org.uberfire.workbench.model.impl.PartDefinitionImpl in project kie-wb-common by kiegroup.
the class AdministrationPerspective method buildPerspective.
@Perspective
public PerspectiveDefinition buildPerspective() {
final PerspectiveDefinition perspective = new PerspectiveDefinitionImpl(MultiListWorkbenchPanelPresenter.class.getName());
perspective.setName(AppConstants.INSTANCE.AdministrationPerspectiveName());
perspective.getRoot().addPart(new PartDefinitionImpl(new DefaultPlaceRequest("RepositoriesEditor")));
final PanelDefinition west = new PanelDefinitionImpl(SimpleWorkbenchPanelPresenter.class.getName());
west.setWidth(300);
west.setMinWidth(200);
west.addPart(new PartDefinitionImpl(new DefaultPlaceRequest("FileExplorer")));
perspective.getRoot().insertChild(CompassPosition.WEST, west);
return perspective;
}
use of org.uberfire.workbench.model.impl.PartDefinitionImpl in project kie-wb-common by kiegroup.
the class CanvasPerspective method buildPerspective.
@Perspective
public PerspectiveDefinition buildPerspective() {
PerspectiveDefinition perspective = new PerspectiveDefinitionImpl(MultiListWorkbenchPanelPresenter.class.getName());
perspective.setName("Canvas only");
perspective.getRoot().addPart(new PartDefinitionImpl(new DefaultPlaceRequest(DiagramsNavigatorScreen.SCREEN_ID)));
return perspective;
}
Aggregations