Examples of beginCompoundChange()


Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

            IDocumentExtension4 extension= (IDocumentExtension4) document;
            DocumentRewriteSessionType type= selection.y == 0 || selection.y > 1000 ? DocumentRewriteSessionType.SEQUENTIAL : DocumentRewriteSessionType.UNRESTRICTED_SMALL;
            rewriteSession= extension.startRewriteSession(type);
          } else {
            setRedraw(false);
            target.beginCompoundChange();
          }

          try {

            final String rememberedContents= document.get();
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

      return;
    }

    IRewriteTarget target = (IRewriteTarget) _componentEditor.getAdapter(IRewriteTarget.class);
    if (target != null) {
      target.beginCompoundChange();
    }

    if (!getTemplateEditor().getSourceEditor().validateEditorInputState()) {
      event.detail = DND.DROP_NONE;
      return;
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

  public static void addKey(AddKeyInfo info) throws CoreException {
    IEditorPart editorPart = JavaUI.openInEditor(info.getComponentType().getCompilationUnit());
    if (editorPart != null) {
      IRewriteTarget target = (IRewriteTarget) editorPart.getAdapter(IRewriteTarget.class);
      if (target != null) {
        target.beginCompoundChange();
      }
      try {
        new AddKeyOperation(info).run(null);
      } finally {
        if (target != null) {
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

  public static void replaceField(AddKeyInfo info, String originalName) throws CoreException {
    IEditorPart editorPart = JavaUI.openInEditor(info.getComponentType().getCompilationUnit());
    if (editorPart != null) {
      IRewriteTarget target = (IRewriteTarget) editorPart.getAdapter(IRewriteTarget.class);
      if (target != null) {
        target.beginCompoundChange();
      }
      try {
        String newName = info.getName();

        info.setName(originalName);
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

      // CompilationUnitEditor cuEditor =
      // (CompilationUnitEditor) editorPart;
      // cuEditor.getDocumentProvider().getDocument(componentType.getCompilationUnit()).get
      IRewriteTarget target = (IRewriteTarget) editorPart.getAdapter(IRewriteTarget.class);
      if (target != null) {
        target.beginCompoundChange();
      }
      try {
        new AddActionOperation(info).run(null);
      }
      finally {
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

    fStrategy.arm(fTextViewer);

    IRewriteTarget target= (IRewriteTarget)editor.getAdapter(IRewriteTarget.class);
    if (target != null) {
      target.beginCompoundChange();
    }
  }

  /**
   * Checks if <code>selection</code> is contained by the visible region of <code>viewer</code>.
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

    ITextEditor editor= getTextEditor();
    if (editor == null || !validateEditorInputState())
      return;
    IRewriteTarget target= (IRewriteTarget)editor.getAdapter(IRewriteTarget.class);
    if (target != null)
      target.beginCompoundChange();
    runCompoundChange();
    if (target != null)
      target.endCompoundChange();

  }
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

        ITextViewerExtension extension= (ITextViewerExtension) fViewer;
        target= extension.getRewriteTarget();
      }

      if (target != null)
        target.beginCompoundChange();

      if (fViewer instanceof IEditingSupportRegistry) {
        IEditingSupportRegistry registry= (IEditingSupportRegistry) fViewer;
        registry.register(helper);
      }
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

        return;
      }

      IRewriteTarget target= (IRewriteTarget)getTextEditor().getAdapter(IRewriteTarget.class);
      if (target != null)
        target.beginCompoundChange();

      fLastCompletion= completionState;
    }
  }
View Full Code Here

Examples of org.eclipse.jface.text.IRewriteTarget.beginCompoundChange()

              ? DocumentRewriteSessionType.SEQUENTIAL
              : DocumentRewriteSessionType.UNRESTRICTED_SMALL;
            rewriteSession= extension.startRewriteSession(type);
          } else {
            setRedraw(false);
            target.beginCompoundChange();
          }

          try {

            final String rememberedContents= document.get();
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.