Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(441)

Unified Diff: ui/gfx/render_text.h

Issue 1989143002: MacViews: Correct behavior of move and select commands when selection direction changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_commands
Patch Set: Address review comments. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/gfx/render_text.cc » ('j') | ui/gfx/render_text.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/render_text.h
diff --git a/ui/gfx/render_text.h b/ui/gfx/render_text.h
index d93d92815793b239eacbddd33c0fb471809654f3..372aae76340fc1c007ff6ef3b1190e5028831a5e 100644
--- a/ui/gfx/render_text.h
+++ b/ui/gfx/render_text.h
@@ -321,9 +321,18 @@ class GFX_EXPORT RenderText {
// Moves the cursor left or right. Cursor movement is visual, meaning that
// left and right are relative to screen, not the directionality of the text.
// If |select| is false, the selection start is moved to the same position.
+ // |select_behavior| specifies the selection behavior in case the selection
+ // direction is reversed.
void MoveCursor(BreakType break_type,
VisualCursorDirection direction,
- bool select);
+ bool select,
+ SelectionReversedBehavior select_behavior);
+
+ void MoveCursor(BreakType break_type,
+ VisualCursorDirection direction,
+ bool select) {
+ MoveCursor(break_type, direction, select, SELECTION_DEFAULT);
+ }
// Set the selection_model_ to the value of |selection|.
// The selection range is clamped to text().length() if out of range.
« no previous file with comments | « no previous file | ui/gfx/render_text.cc » ('j') | ui/gfx/render_text.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698