Search in sources :

Example 1 with BusyViewImpl

use of edu.stanford.bmir.protege.web.client.progress.BusyViewImpl in project webprotege by protegeproject.

the class PerspectivePresenter method retrieveAndSetPerspective.

private void retrieveAndSetPerspective(final PerspectiveId perspectiveId) {
    GWT.log("[PerspectivePresenter] Retrive and set perspective for " + perspectiveId);
    Perspective p = perspectiveCache.get(perspectiveId);
    if (p != null) {
        GWT.log("[PerspectivePresenter] Using cached perspective for " + perspectiveId);
        perspectiveView.setWidget(p);
        return;
    }
    perspectiveView.setWidget(new BusyViewImpl());
    GWT.log("[PerspectivePresenter] Loading perspective for project " + projectId);
    UserId userId = loggedInUserProvider.getCurrentUserId();
    dispatchServiceManager.execute(new GetPerspectiveLayoutAction(projectId, userId, perspectiveId), result -> {
        GWT.log("[PerspectivePresenter] Retrieved layout: " + result.getPerspectiveLayout());
        installPerspective(perspectiveId, result.getPerspectiveLayout());
    });
}
Also used : ResetPerspectiveLayoutAction.resetPerspective(edu.stanford.bmir.protege.web.shared.perspective.ResetPerspectiveLayoutAction.resetPerspective) UserId(edu.stanford.bmir.protege.web.shared.user.UserId) BusyViewImpl(edu.stanford.bmir.protege.web.client.progress.BusyViewImpl)

Aggregations

BusyViewImpl (edu.stanford.bmir.protege.web.client.progress.BusyViewImpl)1 ResetPerspectiveLayoutAction.resetPerspective (edu.stanford.bmir.protege.web.shared.perspective.ResetPerspectiveLayoutAction.resetPerspective)1 UserId (edu.stanford.bmir.protege.web.shared.user.UserId)1