diff options
author | nyamatongwe <devnull@localhost> | 2011-02-28 13:04:34 +1100 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2011-02-28 13:04:34 +1100 |
commit | b7a1aa5a607fad68f65de0d4426af8f50468f1e0 (patch) | |
tree | 977ad66b6734e5e873974dd2d84d8718ed582b01 /src/Editor.cxx | |
parent | eaea293d5ed6a06b496867d86bc7e4b41b0f383b (diff) | |
download | scintilla-mirror-b7a1aa5a607fad68f65de0d4426af8f50468f1e0.tar.gz |
Avoid shadowed variables as reported by Xcode.
Diffstat (limited to 'src/Editor.cxx')
-rw-r--r-- | src/Editor.cxx | 9 |
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) { |