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

Side by Side Diff: components/reading_list/ios/favicon_web_state_dispatcher.h

Issue 2604773002: Create distiller files for Reading List. (Closed)
Patch Set: Created 3 years, 11 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 #ifndef COMPONENTS_DOM_DISTILLER_IOS_FAVICON_WEB_STATE_DISPATCHER_H_ 5 #ifndef COMPONENTS_READING_LIST_IOS_FAVICON_WEB_STATE_DISPATCHER_H_
6 #define COMPONENTS_DOM_DISTILLER_IOS_FAVICON_WEB_STATE_DISPATCHER_H_ 6 #define COMPONENTS_READING_LIST_IOS_FAVICON_WEB_STATE_DISPATCHER_H_
7 7
8 namespace web { 8 namespace web {
9 class WebState; 9 class WebState;
10 } 10 }
11 11
12 namespace dom_distiller { 12 namespace reading_list {
13 13
14 // Dispatcher for WebState having a Favicon Driver, with BookmarkModel and 14 // Dispatcher for WebState having a Favicon Driver, with BookmarkModel and
15 // HistoryService attached, as observer. The Webstates are kept alive between 15 // HistoryService attached, as observer. The Webstates are kept alive between
16 // their creation and their return. After a WebState is returned, the dispatcher 16 // their creation and their return. After a WebState is returned, the dispatcher
gambard 2016/12/27 09:35:58 Update the comment: the webstate is not kept alive
Olivier 2016/12/27 10:08:36 Done.
17 // keeps it alive long enough for it to download the favicons. 17 // keeps it alive long enough for it to download the favicons.
18 class FaviconWebStateDispatcher { 18 class FaviconWebStateDispatcher {
19 public: 19 public:
20 FaviconWebStateDispatcher() {} 20 FaviconWebStateDispatcher() {}
21 virtual ~FaviconWebStateDispatcher() {} 21 virtual ~FaviconWebStateDispatcher() {}
22 // Returns a WebState with a Favicon Driver attached. 22 // Returns a WebState with a Favicon Driver attached.
23 virtual web::WebState* RequestWebState() = 0; 23 virtual std::unique_ptr<web::WebState> RequestWebState() = 0;
24 // Called to return a WebState. The WebState should not be used after being 24 // Called to return a WebState. The WebState should not be used after being
25 // returned. 25 // returned.
26 virtual void ReturnWebState(web::WebState* web_state) = 0; 26 virtual void ReturnWebState(std::unique_ptr<web::WebState> web_state) = 0;
27 27
28 private: 28 private:
29 DISALLOW_COPY_AND_ASSIGN(FaviconWebStateDispatcher); 29 DISALLOW_COPY_AND_ASSIGN(FaviconWebStateDispatcher);
30 }; 30 };
31 31
32 } // namespace dom_distiller 32 } // namespace dom_distiller
gambard 2016/12/27 09:35:58 Update namespace
Olivier 2016/12/27 10:08:36 Done.
33 33
34 #endif // COMPONENTS_DOM_DISTILLER_IOS_FAVICON_WEB_STATE_DISPATCHER_H_ 34 #endif // COMPONENTS_READING_LIST_IOS_FAVICON_WEB_STATE_DISPATCHER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698