.newTopLevelMenu( AppConstants.INSTANCE.Home() )
.respondsWith( new Command() {
@Override
public void execute() {
if ( defaultPerspective != null ) {
placeManager.goTo( new DefaultPlaceRequest( defaultPerspective.getIdentifier() ) );
} else {
Window.alert( "Default perspective not found." );
}
}
} )
.endMenu()
.newTopLevelMenu( AppConstants.INSTANCE.MenuOrganizationalUnits() )
.menus()
.menu( AppConstants.INSTANCE.MenuManageOrganizationalUnits() )
.respondsWith( new Command() {
@Override
public void execute() {
placeManager.goTo( "org.kie.workbench.common.screens.organizationalunit.manager.OrganizationalUnitManager" );
}
} )
.endMenu()
.endMenus()
.endMenu()
.newTopLevelMenu( "Repositories" )
.menus()
.menu( "Repositories List" )
.respondsWith( new Command() {
@Override
public void execute() {
placeManager.goTo( "RepositoriesEditor" );
}
} )
.endMenu()
.menu( "Clone repository" )
.respondsWith( cloneRepoCommand )
.endMenu()
.menu( "New repository" )
.respondsWith( newRepoCommand )
.endMenu()
.endMenus()
.endMenu()
.newTopLevelMenu( "Authoring" ).respondsWith(new Command() {
@Override
public void execute() {
if ( defaultPerspective != null ) {
placeManager.goTo(new DefaultPlaceRequest("org.guvnor.AuthoringPerspective"));
} else {
Window.alert( " perspective not found." );
}
}
} )