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

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

Issue 148403007: Protect AppListItemList Add/Remove and fix sync bugs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 10 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_item.h" 5 #include "ui/app_list/app_list_item.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/app_list/app_list_item_observer.h" 8 #include "ui/app_list/app_list_item_observer.h"
9 9
10 namespace app_list { 10 namespace app_list {
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 return app_type; 81 return app_type;
82 } 82 }
83 83
84 ui::MenuModel* AppListItem::GetContextMenuModel() { 84 ui::MenuModel* AppListItem::GetContextMenuModel() {
85 return NULL; 85 return NULL;
86 } 86 }
87 87
88 bool AppListItem::CompareForTest(const AppListItem* other) const { 88 bool AppListItem::CompareForTest(const AppListItem* other) const {
89 return id_ == other->id_ && 89 return id_ == other->id_ &&
90 title_ == other->title_ && 90 title_ == other->title_ &&
91 GetItemType() == other->GetItemType() &&
91 position_.Equals(other->position_); 92 position_.Equals(other->position_);
92 } 93 }
93 94
94 std::string AppListItem::ToDebugString() const { 95 std::string AppListItem::ToDebugString() const {
95 return id_.substr(0, 8) + " '" + title_ + "'" 96 return id_.substr(0, 8) + " '" + title_ + "'"
96 + " [" + position_.ToDebugString() + "]"; 97 + " [" + position_.ToDebugString() + "]";
97 } 98 }
98 99
99 } // namespace app_list 100 } // namespace app_list
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698