Index: ui/app_list/search_result.h |
diff --git a/ui/app_list/search_result.h b/ui/app_list/search_result.h |
index d533b7937fa60e176fa5c9e6672b15c93f53e9a4..d3b0a0e8b6db0adbcef5fe8491556255760c5ab4 100644 |
--- a/ui/app_list/search_result.h |
+++ b/ui/app_list/search_result.h |
@@ -27,6 +27,12 @@ class SearchResultObserver; |
// default style. |
class APP_LIST_EXPORT SearchResult { |
public: |
+ // How the result should be displayed. |
+ enum DisplayType { |
+ DISPLAY_LIST, |
+ DISPLAY_TILE, |
+ }; |
+ |
// A tagged range in search result text. |
struct APP_LIST_EXPORT Tag { |
// Similar to ACMatchClassification::Style, the style values are not |
@@ -90,6 +96,7 @@ class APP_LIST_EXPORT SearchResult { |
const std::string& id() const { return id_; } |
double relevance() const { return relevance_; } |
+ const DisplayType display_type() const { return display_type_; } |
const Actions& actions() const { |
return actions_; |
@@ -122,6 +129,9 @@ class APP_LIST_EXPORT SearchResult { |
protected: |
void set_id(const std::string& id) { id_ = id; } |
void set_relevance(double relevance) { relevance_ = relevance; } |
+ void set_display_type(DisplayType display_type) { |
+ display_type_ = display_type; |
+ } |
private: |
gfx::ImageSkia icon_; |
@@ -134,6 +144,7 @@ class APP_LIST_EXPORT SearchResult { |
std::string id_; |
double relevance_; |
+ DisplayType display_type_; |
Actions actions_; |