use of com.intellij.cvsSupport2.checkinProject.AdditionalOptionsPanel in project intellij-community by JetBrains.
the class CvsCheckinHandlerFactory method createVcsHandler.
@NotNull
@Override
protected CheckinHandler createVcsHandler(final CheckinProjectPanel panel) {
return new CheckinHandler() {
@Nullable
public RefreshableOnComponent getAfterCheckinConfigurationPanel(Disposable parentDisposable) {
final Project project = panel.getProject();
final CvsVcs2 cvs = CvsVcs2.getInstance(project);
final ProjectLevelVcsManager vcsManager = ProjectLevelVcsManager.getInstance(project);
final Collection<VirtualFile> roots = panel.getRoots();
final Collection<FilePath> files = new HashSet<>();
for (VirtualFile root : roots) {
final VcsRoot vcsRoot = vcsManager.getVcsRootObjectFor(root);
if (vcsRoot == null || vcsRoot.getVcs() != cvs) {
continue;
}
files.add(VcsContextFactory.SERVICE.getInstance().createFilePathOn(root));
}
return new AdditionalOptionsPanel(CvsConfiguration.getInstance(project), files, project);
}
};
}
Aggregations