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

Side by Side Diff: components/reading_list/ios/reading_list_model_bridge_observer.mm

Issue 2888163004: [ObjC ARC] Converts components/reading_list/ios:ios to ARC. (Closed)
Patch Set: Reworded todo. Created 3 years, 6 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 | « components/reading_list/ios/reading_list_model_bridge_observer.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #import "components/reading_list/ios/reading_list_model_bridge_observer.h" 5 #import "components/reading_list/ios/reading_list_model_bridge_observer.h"
6 6
7 #include "components/reading_list/core/reading_list_entry.h" 7 #include "components/reading_list/core/reading_list_entry.h"
8 #include "components/reading_list/core/reading_list_model.h" 8 #include "components/reading_list/core/reading_list_model.h"
9 9
10 #if !defined(__has_feature) || !__has_feature(objc_arc)
11 #error "This file requires ARC support."
12 #endif
13
10 ReadingListModelBridge::ReadingListModelBridge( 14 ReadingListModelBridge::ReadingListModelBridge(
11 id<ReadingListModelBridgeObserver> observer, 15 id<ReadingListModelBridgeObserver> observer,
12 ReadingListModel* model) 16 ReadingListModel* model)
13 : observer_(observer), model_(model) { 17 : observer_(observer), model_(model) {
14 DCHECK(model); 18 DCHECK(model);
15 model_->AddObserver(this); 19 model_->AddObserver(this);
16 } 20 }
17 21
18 ReadingListModelBridge::~ReadingListModelBridge() { 22 ReadingListModelBridge::~ReadingListModelBridge() {
19 if (model_) { 23 if (model_) {
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 } 107 }
104 108
105 void ReadingListModelBridge::ReadingListWillUpdateEntry( 109 void ReadingListModelBridge::ReadingListWillUpdateEntry(
106 const ReadingListModel* model, 110 const ReadingListModel* model,
107 const GURL& url) { 111 const GURL& url) {
108 if ([observer_ 112 if ([observer_
109 respondsToSelector:@selector(readingListModel:willUpdateEntry:)]) { 113 respondsToSelector:@selector(readingListModel:willUpdateEntry:)]) {
110 [observer_ readingListModel:model willUpdateEntry:url]; 114 [observer_ readingListModel:model willUpdateEntry:url];
111 } 115 }
112 } 116 }
OLDNEW
« no previous file with comments | « components/reading_list/ios/reading_list_model_bridge_observer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698