aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Editor.cxx
diff options
context:
space:
mode:
authornyamatongwe <unknown>2011-02-28 13:04:34 +1100
committernyamatongwe <unknown>2011-02-28 13:04:34 +1100
commitf67325b4e01ae0c4656927663f9d03c985119e92 (patch)
tree28765c6ac5c413f33cf6588e089de976150de343 /src/Editor.cxx
parent20f85b2905da617a55328fd56b4a6b485e9aeace (diff)
downloadscintilla-mirror-f67325b4e01ae0c4656927663f9d03c985119e92.tar.gz
Avoid shadowed variables as reported by Xcode.
Diffstat (limited to 'src/Editor.cxx')
-rw-r--r--src/Editor.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index 865633be3..f792d160f 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -705,14 +705,14 @@ void Editor::SetRectangularRange() {
if (sel.selType == Selection::selThin) {
xCaret = xAnchor;
}
- int lineAnchor = pdoc->LineFromPosition(sel.Rectangular().anchor.Position());
+ int lineAnchorRect = pdoc->LineFromPosition(sel.Rectangular().anchor.Position());
int lineCaret = pdoc->LineFromPosition(sel.Rectangular().caret.Position());
- int increment = (lineCaret > lineAnchor) ? 1 : -1;
- for (int line=lineAnchor; line != lineCaret+increment; line += increment) {
+ int increment = (lineCaret > lineAnchorRect) ? 1 : -1;
+ for (int line=lineAnchorRect; line != lineCaret+increment; line += increment) {
SelectionRange range(SPositionFromLineX(line, xCaret), SPositionFromLineX(line, xAnchor));
if ((virtualSpaceOptions & SCVS_RECTANGULARSELECTION) == 0)
range.ClearVirtualSpace();
- if (line == lineAnchor)
+ if (line == lineAnchorRect)
sel.SetSelection(range);
else
sel.AddSelectionWithoutTrim(range);
@@ -4733,7 +4733,6 @@ void Editor::Duplicate(bool forLine) {
forLine = true;
}
UndoGroup ug(pdoc, sel.Count() > 1);
- SelectionPosition last;
const char *eol = "";
int eolLen = 0;
if (forLine) {