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

Side by Side Diff: chrome/browser/ui/views/omnibox/omnibox_result_view_model.h

Issue 10829370: Make search icon in omnibox results hidpi (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_
6 #define CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_ 6 #define CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_
7 7
8 class SkBitmap; 8 namespace gfx {
9 class Image;
10 }
9 11
10 // An interface implemented by an object that provides data to populate 12 // An interface implemented by an object that provides data to populate
11 // individual result views. 13 // individual result views.
12 class OmniboxResultViewModel { 14 class OmniboxResultViewModel {
13 public: 15 public:
14 // Returns true if the index is selected. 16 // Returns true if the index is selected.
15 virtual bool IsSelectedIndex(size_t index) const = 0; 17 virtual bool IsSelectedIndex(size_t index) const = 0;
16 18
17 // Returns true if the index is hovered. 19 // Returns true if the index is hovered.
18 virtual bool IsHoveredIndex(size_t index) const = 0; 20 virtual bool IsHoveredIndex(size_t index) const = 0;
19 21
20 // If |index| is a match from an extension, returns the extension icon; 22 // If |index| is a match from an extension, returns the extension icon;
21 // otherwise returns NULL. 23 // otherwise returns an empty gfx::Image.
22 virtual const SkBitmap* GetIconIfExtensionMatch(size_t index) const = 0; 24 virtual gfx::Image GetIconIfExtensionMatch(size_t index) const = 0;
23 }; 25 };
24 26
25 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_ 27 #endif // CHROME_BROWSER_UI_VIEWS_OMNIBOX_OMNIBOX_RESULT_VIEW_MODEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698