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

Unified Diff: chrome/browser/chromeos/login/username_view.cc

Issue 5158006: Convert SizeStringInt from taking a wstring to a string16. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: mac Created 10 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
« no previous file with comments | « no previous file | chrome/browser/ui/views/sad_tab_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/login/username_view.cc
diff --git a/chrome/browser/chromeos/login/username_view.cc b/chrome/browser/chromeos/login/username_view.cc
index 750c7883680eb00add33e8f8d21b6ba89b712ad4..efc1976b3a5be62aab010f63f3739e63d941a8f1 100644
--- a/chrome/browser/chromeos/login/username_view.cc
+++ b/chrome/browser/chromeos/login/username_view.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/chromeos/login/username_view.h"
#include "base/logging.h"
+#include "base/utf_string_conversions.h"
#include "gfx/canvas.h"
#include "gfx/canvas_skia.h"
#include "gfx/rect.h"
@@ -78,7 +79,7 @@ void UsernameView::PaintUsername(const gfx::Rect& bounds) {
gfx::Canvas::TEXT_VALIGN_MIDDLE |
gfx::Canvas::NO_ELLIPSIS;
int text_height;
- gfx::CanvasSkia::SizeStringInt(GetText(), font(),
+ gfx::CanvasSkia::SizeStringInt(WideToUTF16Hack(GetText()), font(),
&text_width_, &text_height,
flags);
text_width_ = std::min(text_width_, bounds.width() - margin_width_);
« no previous file with comments | « no previous file | chrome/browser/ui/views/sad_tab_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698