congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
PlaceManager.closeAllPlaces
Code IndexAdd Tabnine to your IDE (free)

How to use
closeAllPlaces
method
in
org.uberfire.client.mvp.PlaceManager

Best Java code snippets using org.uberfire.client.mvp.PlaceManager.closeAllPlaces (Showing top 6 results out of 315)

origin: kiegroup/appformer

  @Override
  public void execute() {
    placeManager.closeAllPlaces(); // would be preferable to close current perspective, which should be recursive
  }
};
origin: org.kie.workbench.screens/kie-wb-common-library-client

void closeAllPlaces() {
  closingLibraryPlaces = true;
  placeManager.closeAllPlaces();
  closingLibraryPlaces = false;
}
origin: org.kie.workbench.screens/kie-wb-common-library-client

@Test
public void closeAllPlacesOrNothingWithoutUncloseablePlacesTest() {
  final Command successCallback = mock(Command.class);
  final List<PlaceRequest> uncloseablePlaces = new ArrayList<>();
  uncloseablePlaces.add(mock(PlaceRequest.class));
  libraryPlaces.closeAllPlacesOrNothing(successCallback);
  verify(placeManager).closeAllPlaces();
  verify(successCallback).execute();
  verify(closeUnsavedProjectAssetsPopUpPresenter,
      never()).show(any(),
             any(),
             any(),
             any());
}
origin: org.kie.workbench.screens/kie-wb-common-library-client

@Test
public void goToNewProject() {
  final WorkspaceProject project = new WorkspaceProject(activeOrganizationalUnit,
                             activeRepository,
                             activeBranch,
                             mock(Module.class));
  final Branch lastOpenedBranch = new Branch("master", mock(Path.class));
  doReturn(Optional.of(lastOpenedBranch)).when(libraryInternalPreferences).getLastBranchOpened(project);
  doReturn(activeProject).when(projectService).resolveProject(activeSpace, lastOpenedBranch);
  libraryPlaces.goToProject(project);
  verify(libraryPlaces).goToProject(project, lastOpenedBranch);
  verify(projectContextChangeEvent).fire(any(WorkspaceProjectContextChangeEvent.class));
  verify(placeManager).closeAllPlaces();
}
origin: org.kie.workbench.screens/kie-wb-common-library-client

public void closeAllPlacesOrNothing(final Command successCallback) {
  closingLibraryPlaces = true;
  final List<PlaceRequest> uncloseablePlaces = placeManager.getUncloseablePlaces();
  if (uncloseablePlaces != null && uncloseablePlaces.isEmpty()) {
    placeManager.closeAllPlaces();
    closingLibraryPlaces = false;
    if (successCallback != null) {
      successCallback.execute();
    }
  } else {
    final Command newSuccessCallback = () -> {
      placeManager.forceCloseAllPlaces();
      closingLibraryPlaces = false;
      if (successCallback != null) {
        successCallback.execute();
      }
    };
    closeUnsavedProjectAssetsPopUpPresenter.show(getActiveWorkspace(),
                           uncloseablePlaces,
                           newSuccessCallback,
                           () -> placeManager.goTo(uncloseablePlaces.get(0)));
  }
}
origin: org.kie.workbench.screens/kie-wb-common-library-client

@Test
public void goToOrganizationalUnitsTest() {
  final PlaceRequest placeRequest = new DefaultPlaceRequest(LibraryPlaces.ORGANIZATIONAL_UNITS_SCREEN);
  final PartDefinitionImpl part = new PartDefinitionImpl(placeRequest);
  part.setSelectable(false);
  libraryPlaces.goToOrganizationalUnits();
  verify(projectContextChangeEvent).fire(projectContextChangeEventArgumentCaptor.capture());
  assertNull(projectContextChangeEventArgumentCaptor.getValue().getOrganizationalUnit());
  final ArgumentCaptor<WorkspaceProjectContextChangeEvent> eventArgumentCaptor = ArgumentCaptor.forClass(WorkspaceProjectContextChangeEvent.class);
  verify(projectContextChangeEvent).fire(eventArgumentCaptor.capture());
  final WorkspaceProjectContextChangeEvent event = eventArgumentCaptor.getValue();
  assertNull(event.getOrganizationalUnit());
  assertNull(event.getWorkspaceProject());
  verify(placeManager).closeAllPlaces();
  verify(placeManager).goTo(eq(part),
               any(PanelDefinition.class));
  verify(libraryBreadcrumbs).setupForSpacesScreen();
}
org.uberfire.client.mvpPlaceManagercloseAllPlaces

Popular methods of PlaceManager

  • goTo
  • closePlace
  • forceClosePlace
  • getStatus
  • tryClosePlace
  • executeOnCloseCallbacks
  • executeOnOpenCallbacks
  • getActivity
  • registerOnOpenCallback
  • forceCloseAllPlaces
  • getOnOpenCallbacks
  • getUncloseablePlaces
  • getOnOpenCallbacks,
  • getUncloseablePlaces,
  • registerOnCloseCallback,
  • canClosePlace,
  • getActiveSplashScreens,
  • getCurrentPlaceRequest,
  • getOnCloseCallbacks,
  • registerPerspectiveCloseChain

Popular in Java

  • Creating JSON documents from java classes using gson
  • getResourceAsStream (ClassLoader)
  • requestLocationUpdates (LocationManager)
  • getExternalFilesDir (Context)
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • Executor (java.util.concurrent)
    An object that executes submitted Runnable tasks. This interface provides a way of decoupling task s
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • BoxLayout (javax.swing)
  • Top 12 Jupyter Notebook Extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now