public void flushChange() { if (change == null) return; for (InnerRange range : innerRanges) { range.shift(myCurrentShift); } innerRanges.trimToSize(); change = TrimUtil.expand(myVcs, myCurrent, change.start1, change.start2, change.end1, change.end2); int currentLine1 = myCurrentShift + change.start2; int currentLine2 = myCurrentShift + change.end2; int vcsLine1 = myVcsShift + change.start1; int vcsLine2 = myVcsShift + change.end1; myRanges.add(new Range(currentLine1, currentLine2, vcsLine1, vcsLine2, innerRanges)); change = null; innerRanges = null; }
@Override protected void addChange(int start1, int start2, int end1, int end2) { Range range = TrimUtil.expand(myObjects1, myObjects2, start1, start2, end1, end2); super.addChange(range.start1, range.start2, range.end1, range.end2); }