Search in sources :

Example 1 with WatchOperation

use of com.intellij.cvsSupport2.cvsoperations.cvsWatch.WatchOperation in project intellij-community by JetBrains.

the class AbstractWatchAction method getCvsHandler.

protected CvsHandler getCvsHandler(CvsContext context) {
    CvsConfiguration configuration = CvsConfiguration.getInstance(context.getProject());
    WatcherDialog dialog = createDialog(configuration, context);
    if (!dialog.showAndGet()) {
        return CvsHandler.NULL;
    }
    Watch watch = dialog.getWatch();
    saveWatch(configuration, watch);
    WatchOperation watchOperation = new WatchOperation(getWatchOperation(), watch);
    VirtualFile[] files = context.getSelectedFiles();
    for (int i = 0; i < files.length; i++) {
        watchOperation.addFile(files[i]);
    }
    return new CommandCvsHandler(getTitle(context), watchOperation);
}
Also used : VirtualFile(com.intellij.openapi.vfs.VirtualFile) CvsConfiguration(com.intellij.cvsSupport2.config.CvsConfiguration) WatcherDialog(com.intellij.cvsSupport2.cvsoperations.cvsWatch.ui.WatcherDialog) Watch(org.netbeans.lib.cvsclient.command.Watch) CommandCvsHandler(com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler) WatchOperation(com.intellij.cvsSupport2.cvsoperations.cvsWatch.WatchOperation)

Example 2 with WatchOperation

use of com.intellij.cvsSupport2.cvsoperations.cvsWatch.WatchOperation in project intellij-community by JetBrains.

the class AbstractWatchOnOffAction method getCvsHandler.

protected CvsHandler getCvsHandler(CvsContext context) {
    WatchOperation watchOperation = new WatchOperation(getMode());
    VirtualFile[] files = context.getSelectedFiles();
    for (VirtualFile file : files) {
        watchOperation.addFile(file);
    }
    return new CommandCvsHandler(getTitle(context), watchOperation);
}
Also used : VirtualFile(com.intellij.openapi.vfs.VirtualFile) CommandCvsHandler(com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler) WatchOperation(com.intellij.cvsSupport2.cvsoperations.cvsWatch.WatchOperation)

Aggregations

CommandCvsHandler (com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler)2 WatchOperation (com.intellij.cvsSupport2.cvsoperations.cvsWatch.WatchOperation)2 VirtualFile (com.intellij.openapi.vfs.VirtualFile)2 CvsConfiguration (com.intellij.cvsSupport2.config.CvsConfiguration)1 WatcherDialog (com.intellij.cvsSupport2.cvsoperations.cvsWatch.ui.WatcherDialog)1 Watch (org.netbeans.lib.cvsclient.command.Watch)1