Search in sources :

Example 1 with ProjectScreen

use of com.google.gerrit.client.admin.ProjectScreen in project gerrit by GerritCodeReview.

the class ProjectLinkMenuItem method onScreenLoad.

@Override
public void onScreenLoad(ScreenLoadEvent event) {
    Screen screen = event.getScreen();
    Project.NameKey projectKey;
    if (screen instanceof ProjectScreen) {
        projectKey = ((ProjectScreen) screen).getProjectKey();
    } else {
        projectKey = ProjectScreen.getSavedKey();
    }
    if (projectKey != null) {
        setVisible(true);
        onScreenLoad(projectKey);
    } else {
        setVisible(false);
    }
    super.onScreenLoad(event);
}
Also used : Project(com.google.gerrit.reviewdb.client.Project) ProjectScreen(com.google.gerrit.client.admin.ProjectScreen) ProjectScreen(com.google.gerrit.client.admin.ProjectScreen)

Aggregations

ProjectScreen (com.google.gerrit.client.admin.ProjectScreen)1 Project (com.google.gerrit.reviewdb.client.Project)1