Search in sources :

Example 1 with ModalityContextImpl

use of com.intellij.cvsSupport2.cvsExecution.ModalityContextImpl in project intellij-community by JetBrains.

the class TagsHelper method getBranchesProvider.

private static BranchesProvider getBranchesProvider(CvsOperation operation, Project project) throws VcsException {
    LOG.assertTrue(operation instanceof BranchesProvider);
    final CvsOperationExecutor executor = new CvsOperationExecutor(true, project, new ModalityContextImpl(ModalityState.defaultModalityState()));
    final CommandCvsHandler handler = new CommandCvsHandler(CvsBundle.message("load.tags.operation.name"), operation, true);
    executor.performActionSync(handler, CvsOperationExecutorCallback.EMPTY);
    final CvsResult executionResult = executor.getResult();
    if (executionResult.hasErrors())
        throw executionResult.composeError();
    return (BranchesProvider) operation;
}
Also used : CvsOperationExecutor(com.intellij.cvsSupport2.cvsExecution.CvsOperationExecutor) CommandCvsHandler(com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler) ModalityContextImpl(com.intellij.cvsSupport2.cvsExecution.ModalityContextImpl) CvsResult(com.intellij.openapi.cvsIntegration.CvsResult)

Aggregations

CvsOperationExecutor (com.intellij.cvsSupport2.cvsExecution.CvsOperationExecutor)1 ModalityContextImpl (com.intellij.cvsSupport2.cvsExecution.ModalityContextImpl)1 CommandCvsHandler (com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler)1 CvsResult (com.intellij.openapi.cvsIntegration.CvsResult)1