summaryrefslogtreecommitdiffstats
path: root/chrome/views
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/views')
-rw-r--r--chrome/views/controls/text_field.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/chrome/views/controls/text_field.cc b/chrome/views/controls/text_field.cc
index 3818836..fa35854 100644
--- a/chrome/views/controls/text_field.cc
+++ b/chrome/views/controls/text_field.cc
@@ -343,9 +343,9 @@ std::wstring TextField::Edit::GetSelectedText() const {
}
void TextField::Edit::SelectAll() {
- // Using (0, -1) here is equivalent to calling SetSelAll(); both will select
- // the "phantom newline" that we're trying to avoid.
- SetSel(0, GetTextLength());
+ // Select from the end to the front so that the first part of the text is
+ // always visible.
+ SetSel(GetTextLength(), 0);
}
void TextField::Edit::ClearSelection() {