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

Side by Side Diff: ui/app_list/app_list_model.cc

Issue 11371003: app_list: Add sync animation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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
« no previous file with comments | « ui/app_list/app_list_model.h ('k') | ui/app_list/app_list_model_observer.h » ('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 "ui/app_list/app_list_model.h" 5 #include "ui/app_list/app_list_model.h"
6 6
7 #include "ui/app_list/app_list_item_model.h" 7 #include "ui/app_list/app_list_item_model.h"
8 #include "ui/app_list/app_list_model_observer.h"
8 #include "ui/app_list/search_box_model.h" 9 #include "ui/app_list/search_box_model.h"
9 #include "ui/app_list/search_result.h" 10 #include "ui/app_list/search_result.h"
10 11
11 namespace app_list { 12 namespace app_list {
12 13
13 AppListModel::AppListModel() 14 AppListModel::AppListModel()
14 : apps_(new Apps), 15 : apps_(new Apps),
15 search_box_(new SearchBoxModel), 16 search_box_(new SearchBoxModel),
16 results_(new SearchResults) { 17 results_(new SearchResults) {
sky 2012/11/07 00:22:30 Initialize status_ ?
xiyuan 2012/11/07 00:56:03 Oops. Fixed.
17 } 18 }
18 19
19 AppListModel::~AppListModel() { 20 AppListModel::~AppListModel() {
20 } 21 }
21 22
23 void AppListModel::AddObserver(AppListModelObserver* observer) {
24 observers_.AddObserver(observer);
25 }
26
27 void AppListModel::RemoveObserver(AppListModelObserver* observer) {
28 observers_.RemoveObserver(observer);
29 }
30
31 void AppListModel::SetStatus(Status status) {
32 if (status_ == status)
33 return;
34
35 status_ = status;
36 FOR_EACH_OBSERVER(AppListModelObserver,
37 observers_,
38 OnAppListModelStatusChanged());
39 }
40
22 } // namespace app_list 41 } // namespace app_list
OLDNEW
« no previous file with comments | « ui/app_list/app_list_model.h ('k') | ui/app_list/app_list_model_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698