Author: dazarov
Date: 2011-12-23 13:29:41 -0500 (Fri, 23 Dec 2011)
New Revision: 37563
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/ChangeAnnotationMarkerResolution.java
Log:
Java Seam and CDI quick fixes: after quick fix, editor is scrolled to the beginning. If
Undo/Redo commands are used, the entire file content gets selected
https://issues.jboss.org/browse/JBIDE-10536
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/ChangeAnnotationMarkerResolution.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/ChangeAnnotationMarkerResolution.java 2011-12-23
17:49:39 UTC (rev 37562)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/marker/ChangeAnnotationMarkerResolution.java 2011-12-23
18:29:41 UTC (rev 37563)
@@ -101,12 +101,9 @@
IAnnotation workingCopyAnnotation =
CDIMarkerResolutionUtils.findWorkingCopy(compilationUnit, annotation);
- //IBuffer buffer = compilationUnit.getBuffer();
TextEdit re = new ReplaceEdit(workingCopyAnnotation.getSourceRange().getOffset(),
workingCopyAnnotation.getSourceRange().getLength(), changeString);
edit.addChild(re);
- //buffer.replace(workingCopyAnnotation.getSourceRange().getOffset(),
workingCopyAnnotation.getSourceRange().getLength(), changeString);
-
if(edit.hasChildren()){
change.perform(new NullProgressMonitor());
original.reconcile(ICompilationUnit.NO_AST, false, null, new NullProgressMonitor());