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

Side by Side Diff: chrome/browser/autocomplete/autocomplete_edit_view_win.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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/autocomplete/autocomplete_edit_view_win.h" 5 #include "chrome/browser/autocomplete/autocomplete_edit_view_win.h"
6 6
7 #include <locale> 7 #include <locale>
8 8
9 #include "app/gfx/chrome_canvas.h" 9 #include "app/gfx/chrome_canvas.h"
10 #include "app/l10n_util.h" 10 #include "app/l10n_util.h"
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
383 iat_patch::IATPatchFunction end_paint_; 383 iat_patch::IATPatchFunction end_paint_;
384 384
385 DISALLOW_COPY_AND_ASSIGN(PaintPatcher); 385 DISALLOW_COPY_AND_ASSIGN(PaintPatcher);
386 }; 386 };
387 387
388 base::LazyInstance<PaintPatcher> g_paint_patcher(base::LINKER_INITIALIZED); 388 base::LazyInstance<PaintPatcher> g_paint_patcher(base::LINKER_INITIALIZED);
389 389
390 } // namespace 390 } // namespace
391 391
392 AutocompleteEditViewWin::AutocompleteEditViewWin( 392 AutocompleteEditViewWin::AutocompleteEditViewWin(
393 const ChromeFont& font, 393 const gfx::Font& font,
394 AutocompleteEditController* controller, 394 AutocompleteEditController* controller,
395 ToolbarModel* toolbar_model, 395 ToolbarModel* toolbar_model,
396 views::View* parent_view, 396 views::View* parent_view,
397 HWND hwnd, 397 HWND hwnd,
398 Profile* profile, 398 Profile* profile,
399 CommandUpdater* command_updater, 399 CommandUpdater* command_updater,
400 bool popup_window_mode, 400 bool popup_window_mode,
401 AutocompletePopupPositioner* popup_positioner) 401 AutocompletePopupPositioner* popup_positioner)
402 : model_(new AutocompleteEditModel(this, controller, profile)), 402 : model_(new AutocompleteEditModel(this, controller, profile)),
403 popup_view_(AutocompletePopupView::CreatePopupView(font, this, 403 popup_view_(AutocompletePopupView::CreatePopupView(font, this,
(...skipping 1849 matching lines...) Expand 10 before | Expand all | Expand 10 after
2253 } 2253 }
2254 2254
2255 void AutocompleteEditViewWin::RepaintDropHighlight(int position) { 2255 void AutocompleteEditViewWin::RepaintDropHighlight(int position) {
2256 if ((position != -1) && (position <= GetTextLength())) { 2256 if ((position != -1) && (position <= GetTextLength())) {
2257 const POINT min_loc(PosFromChar(position)); 2257 const POINT min_loc(PosFromChar(position));
2258 const RECT highlight_bounds = {min_loc.x - 1, font_y_adjustment_, 2258 const RECT highlight_bounds = {min_loc.x - 1, font_y_adjustment_,
2259 min_loc.x + 2, font_ascent_ + font_descent_ + font_y_adjustment_}; 2259 min_loc.x + 2, font_ascent_ + font_descent_ + font_y_adjustment_};
2260 InvalidateRect(&highlight_bounds, false); 2260 InvalidateRect(&highlight_bounds, false);
2261 } 2261 }
2262 } 2262 }
OLDNEW
« no previous file with comments | « chrome/browser/autocomplete/autocomplete_edit_view_win.h ('k') | chrome/browser/autocomplete/autocomplete_popup_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698