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

Side by Side Diff: components/reading_list/core/reading_list_model.cc

Issue 2763233003: Move ReadingList model to components/reading_list/core (Closed)
Patch Set: feedback Created 3 years, 9 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "components/reading_list/ios/reading_list_model.h" 5 #include "components/reading_list/core/reading_list_model.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 9
10 ReadingListModel::ReadingListModel() : current_batch_updates_count_(0) {} 10 ReadingListModel::ReadingListModel() : current_batch_updates_count_(0) {}
11 11
12 ReadingListModel::~ReadingListModel() { 12 ReadingListModel::~ReadingListModel() {
13 for (auto& observer : observers_) { 13 for (auto& observer : observers_) {
14 observer.ReadingListModelBeingDeleted(this); 14 observer.ReadingListModelBeingDeleted(this);
15 } 15 }
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 void ReadingListModel::LeavingBatchUpdates() { 72 void ReadingListModel::LeavingBatchUpdates() {
73 DCHECK(CalledOnValidThread()); 73 DCHECK(CalledOnValidThread());
74 for (auto& observer : observers_) 74 for (auto& observer : observers_)
75 observer.ReadingListModelCompletedBatchUpdates(this); 75 observer.ReadingListModelCompletedBatchUpdates(this);
76 } 76 }
77 77
78 ReadingListModel::ScopedReadingListBatchUpdate:: 78 ReadingListModel::ScopedReadingListBatchUpdate::
79 ~ScopedReadingListBatchUpdate() { 79 ~ScopedReadingListBatchUpdate() {
80 model_->EndBatchUpdates(); 80 model_->EndBatchUpdates();
81 } 81 }
OLDNEW
« no previous file with comments | « components/reading_list/core/reading_list_model.h ('k') | components/reading_list/core/reading_list_model_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698