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

Unified Diff: views/controls/menu/chrome_menu.cc

Issue 113441: ChromeFont->gfx::Font... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: Created 11 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 | « views/controls/menu/chrome_menu.h ('k') | views/controls/menu/menu_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/controls/menu/chrome_menu.cc
===================================================================
--- views/controls/menu/chrome_menu.cc (revision 16106)
+++ views/controls/menu/chrome_menu.cc (working copy)
@@ -126,14 +126,14 @@
namespace {
// Returns the font menus are to use.
-ChromeFont GetMenuFont() {
+gfx::Font GetMenuFont() {
NONCLIENTMETRICS metrics;
win_util::GetNonClientMetrics(&metrics);
l10n_util::AdjustUIFont(&(metrics.lfMenuFont));
HFONT font = CreateFontIndirect(&metrics.lfMenuFont);
DLOG_ASSERT(font);
- return ChromeFont::CreateFont(font);
+ return gfx::Font::CreateFont(font);
}
// Calculates all sizes that we can from the OS.
@@ -1215,7 +1215,7 @@
}
gfx::Size MenuItemView::GetPreferredSize() {
- ChromeFont& font = GetRootMenuItem()->font_;
+ gfx::Font& font = GetRootMenuItem()->font_;
return gfx::Size(
font.GetStringWidth(title_) + label_start + item_right_margin,
font.height() + GetBottomMargin() + GetTopMargin());
@@ -1487,7 +1487,7 @@
NativeTheme::MENU, MENU_POPUPITEM, state, TMT_TEXTCOLOR,
default_sys_color);
int width = this->width() - item_right_margin - label_start;
- ChromeFont& font = GetRootMenuItem()->font_;
+ gfx::Font& font = GetRootMenuItem()->font_;
gfx::Rect text_bounds(label_start, top_margin, width, font.height());
text_bounds.set_x(MirroredLeftPointForRect(text_bounds));
if (for_drag) {
« no previous file with comments | « views/controls/menu/chrome_menu.h ('k') | views/controls/menu/menu_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698