use of com.google.idea.blaze.base.projectview.ProjectViewSet in project intellij by bazelbuild.
the class OpenAllProjectViewsAction method actionPerformedInBlazeProject.
@Override
protected void actionPerformedInBlazeProject(Project project, AnActionEvent e) {
ProjectViewSet projectViewSet = ProjectViewManager.getInstance(project).getProjectViewSet();
if (projectViewSet == null) {
return;
}
projectViewSet.getProjectViewFiles().forEach(f -> ProjectViewHelper.openProjectViewFile(project, f));
}
use of com.google.idea.blaze.base.projectview.ProjectViewSet in project intellij by bazelbuild.
the class OpenAllProjectViewsAction method updateForBlazeProject.
@Override
protected void updateForBlazeProject(Project project, AnActionEvent e) {
ProjectViewSet projectViewSet = ProjectViewManager.getInstance(project).getProjectViewSet();
ActionPresentationHelper.of(e).disableIf(projectViewSet == null).commit();
}
use of com.google.idea.blaze.base.projectview.ProjectViewSet in project intellij by bazelbuild.
the class OpenLocalProjectViewAction method updateForBlazeProject.
@Override
protected void updateForBlazeProject(Project project, AnActionEvent e) {
ProjectViewSet projectViewSet = ProjectViewManager.getInstance(project).getProjectViewSet();
ActionPresentationHelper.of(e).disableIf(projectViewSet == null).commit();
}
use of com.google.idea.blaze.base.projectview.ProjectViewSet in project intellij by bazelbuild.
the class OpenLocalProjectViewAction method openLocalProjectViewFile.
/**
* Opens the user's local project view file.
*/
public static void openLocalProjectViewFile(Project project) {
ProjectViewSet projectViewSet = ProjectViewManager.getInstance(project).getProjectViewSet();
if (projectViewSet == null) {
return;
}
ProjectViewHelper.openProjectViewFile(project, projectViewSet.getTopLevelProjectViewFile());
}
use of com.google.idea.blaze.base.projectview.ProjectViewSet in project intellij by bazelbuild.
the class ProjectViewUi method parseProjectView.
public ProjectViewSet parseProjectView(final List<IssueOutput> issues) {
final String projectViewText = projectViewEditor.getDocument().getText();
final OutputSink<IssueOutput> issueCollector = output -> {
issues.add(output);
return OutputSink.Propagation.Continue;
};
return Scope.root(context -> {
context.addOutputSink(IssueOutput.class, issueCollector);
ProjectViewParser projectViewParser = new ProjectViewParser(context, workspacePathResolver);
projectViewParser.parseProjectView(projectViewText);
return projectViewParser.getResult();
});
}
Aggregations