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

Side by Side Diff: ash/shell/app_list.cc

Issue 621823004: Simplifies the structure of app_list search a bit. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 2 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
« no previous file with comments | « no previous file | athena/home/app_list_view_delegate.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include <string> 5 #include <string>
6 #include <vector> 6 #include <vector>
7 7
8 #include "ash/session/session_state_delegate.h" 8 #include "ash/session/session_state_delegate.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/shell/example_factory.h" 10 #include "ash/shell/example_factory.h"
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 base::string16 details = 181 base::string16 details =
182 base::UTF8ToUTF16(WindowTypeShelfItem::GetDetails(type_)); 182 base::UTF8ToUTF16(WindowTypeShelfItem::GetDetails(type_));
183 set_details(details); 183 set_details(details);
184 Tags details_tags; 184 Tags details_tags;
185 details_tags.push_back(Tag(Tag::DIM, 0, details.length())); 185 details_tags.push_back(Tag(Tag::DIM, 0, details.length()));
186 set_details_tags(details_tags); 186 set_details_tags(details_tags);
187 } 187 }
188 188
189 WindowTypeShelfItem::Type type() const { return type_; } 189 WindowTypeShelfItem::Type type() const { return type_; }
190 190
191 // app_list::SearchResult:
192 virtual scoped_ptr<SearchResult> Duplicate() override {
193 return scoped_ptr<SearchResult>();
194 }
195
191 private: 196 private:
192 WindowTypeShelfItem::Type type_; 197 WindowTypeShelfItem::Type type_;
193 198
194 DISALLOW_COPY_AND_ASSIGN(ExampleSearchResult); 199 DISALLOW_COPY_AND_ASSIGN(ExampleSearchResult);
195 }; 200 };
196 201
197 class ExampleAppListViewDelegate : public app_list::AppListViewDelegate { 202 class ExampleAppListViewDelegate : public app_list::AppListViewDelegate {
198 public: 203 public:
199 ExampleAppListViewDelegate() 204 ExampleAppListViewDelegate()
200 : model_(new app_list::AppListModel) { 205 : model_(new app_list::AppListModel) {
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 }; 374 };
370 375
371 } // namespace 376 } // namespace
372 377
373 app_list::AppListViewDelegate* CreateAppListViewDelegate() { 378 app_list::AppListViewDelegate* CreateAppListViewDelegate() {
374 return new ExampleAppListViewDelegate; 379 return new ExampleAppListViewDelegate;
375 } 380 }
376 381
377 } // namespace shell 382 } // namespace shell
378 } // namespace ash 383 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | athena/home/app_list_view_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698