@Override
  public void execute(boolean batchMode, @NotNull Runnable operation) {
    EditorImpl.assertIsDispatchThread();
    if (myInBatchMode || !batchMode) {
      operation.run();
    }
    else {
      try {
        notifyBatchModeStarting();
        myInBatchMode = true;
        operation.run();
      }
      finally {
        myInBatchMode = false;
        notifyBatchModeFinished();
      }
    }
  }
@Override
  public void execute(boolean batchMode, @NotNull Runnable operation)