Examples of MksVcs


Examples of org.intellij.vcs.mks.MksVcs

        FileDocumentManager.getInstance().saveAllDocuments();
      }
    });
        final VirtualFile[] vFiles = getVirtualFiles(event);

    final MksVcs mksvcs = MksVcs.getInstance(project);
    if (!ProjectLevelVcsManager.getInstance(project).checkAllFilesAreUnder(mksvcs, vFiles)) {
      return;
    }

    final List<VcsException> exceptions = new ArrayList<VcsException>();
    ApplicationManager.getApplication().runWriteAction(new Runnable() {
      public void run() {
        final VirtualFile[] affectedFiles = collectAffectedFiles(project, vFiles);
        //noinspection unchecked
        perform(project, mksvcs, exceptions, affectedFiles);
        for (VirtualFile file : affectedFiles) {
          file.refresh(false, true);
          FileStatusManager.getInstance(project).fileStatusChanged(file);
        }
      }
    });
    mksvcs.showErrors(exceptions, getActionName(mksvcs));


  }
View Full Code Here

Examples of org.intellij.vcs.mks.MksVcs

    if (vFiles == null || vFiles.length == 0) {
      presentation.setEnabled(false);
      presentation.setVisible(true);
      return;
    }
    MksVcs mksvcs = MksVcs.getInstance(project);
    boolean enabled = ProjectLevelVcsManager.getInstance(project).checkAllFilesAreUnder(mksvcs, vFiles)
        && isEnabled(project, mksvcs, vFiles);
    // only enable action if all the targets are under the vcs and the action suports all of them

    presentation.setEnabled(enabled);
View Full Code Here

Examples of org.intellij.vcs.mks.MksVcs

*/
public class ViewChangePackageAction extends AnAction {
    @Override public void update(final AnActionEvent e) {
        final DataContext dataContext = e.getDataContext();
        final Project project = PlatformDataKeys.PROJECT.getData(dataContext);
        final MksVcs mksVcs = MksVcs.getInstance(project);
        e.getPresentation().setEnabled(!getSelectedChangePackages(dataContext, mksVcs).isEmpty());
    }
View Full Code Here

Examples of org.intellij.vcs.mks.MksVcs

    @Override
    public void actionPerformed(final AnActionEvent anActionEvent) {
        final DataContext dataContext = anActionEvent.getDataContext();
        final Project project = PlatformDataKeys.PROJECT.getData(dataContext);
        final MksVcs mksVcs = MksVcs.getInstance(project);

        final ArrayList<VcsException> errors = new ArrayList<VcsException>();
        for (final MksChangePackage aPackage : getSelectedChangePackages(dataContext, mksVcs)) {
            new ViewChangePackageAPICommand(errors, mksVcs, aPackage).execute();
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.