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

Unified Diff: ui/gfx/render_text.cc

Issue 8476019: ui/gfx: Convert Canvas::DrawRectInt() to use gfx::Rect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address Peter's review Created 9 years, 1 month 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
Index: ui/gfx/render_text.cc
diff --git a/ui/gfx/render_text.cc b/ui/gfx/render_text.cc
index b6fb3590c76bea025a3c82fbda18c618b65e8881..3f9f91ad4c9326082371b9709877e3dd954e229f 100644
--- a/ui/gfx/render_text.cc
+++ b/ui/gfx/render_text.cc
@@ -387,10 +387,8 @@ void RenderText::Draw(Canvas* canvas) {
}
// Paint cursor. Replace cursor is drawn as rectangle for now.
- Rect cursor(GetUpdatedCursorBounds());
if (cursor_visible() && focused())
- canvas->DrawRectInt(kCursorColor, cursor.x(), cursor.y(),
- cursor.width(), cursor.height());
+ canvas->DrawRect(GetUpdatedCursorBounds(), kCursorColor);
}
SelectionModel RenderText::FindCursorPosition(const Point& point) {

Powered by Google App Engine
This is Rietveld 408576698