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

Unified Diff: ui/views/controls/textfield/textfield.cc

Issue 248863002: MacViews: Introduce native_cursor.h to provide cursor "literals" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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 | « ui/views/controls/table/table_header.cc ('k') | ui/views/native_cursor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/textfield/textfield.cc
diff --git a/ui/views/controls/textfield/textfield.cc b/ui/views/controls/textfield/textfield.cc
index c46ddd24b6d8b7bc5236e7e5fd83758772cb13ed..26b6fd9f8d567305d15a38dda0b935089578f7b9 100644
--- a/ui/views/controls/textfield/textfield.cc
+++ b/ui/views/controls/textfield/textfield.cc
@@ -32,6 +32,7 @@
#include "ui/views/drag_utils.h"
#include "ui/views/ime/input_method.h"
#include "ui/views/metrics.h"
+#include "ui/views/native_cursor.h"
#include "ui/views/painter.h"
#include "ui/views/views_delegate.h"
#include "ui/views/widget/widget.h"
@@ -490,7 +491,7 @@ gfx::NativeCursor Textfield::GetCursor(const ui::MouseEvent& event) {
bool in_selection = GetRenderText()->IsPointInSelection(event.location());
bool drag_event = event.type() == ui::ET_MOUSE_DRAGGED;
bool text_cursor = !initiating_drag_ && (drag_event || !in_selection);
- return text_cursor ? ui::kCursorIBeam : ui::kCursorNull;
+ return text_cursor ? GetNativeIBeamCursor() : gfx::kNullCursor;
}
bool Textfield::OnMousePressed(const ui::MouseEvent& event) {
« no previous file with comments | « ui/views/controls/table/table_header.cc ('k') | ui/views/native_cursor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698