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

Side by Side Diff: ios/chrome/browser/dom_distiller/web_state_dispatcher_impl.h

Issue 2529283002: Save favicon during reading list distillation (Closed)
Patch Set: Add DependsOn Created 4 years 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef IOS_CHROME_BROWSER_DOM_DISTILLER_WEB_STATE_DISPATCHER_IMPL_H_
6 #define IOS_CHROME_BROWSER_DOM_DISTILLER_WEB_STATE_DISPATCHER_IMPL_H_
7
8 #include <map>
9 #include <memory>
10
11 #include "base/memory/weak_ptr.h"
12 #include "components/dom_distiller/ios/web_state_dispatcher.h"
13
14 namespace web {
15 class BrowserState;
16 }
17
18 namespace dom_distiller {
19
20 // Implementation of the WebStateDispatcher.
21 class WebStateDispatcherImpl : public WebStateDispatcher {
22 public:
23 WebStateDispatcherImpl(web::BrowserState* browser_state);
24 ~WebStateDispatcherImpl() override;
25
26 // WebStateDispatcher implementation.
27 web::WebState* RequestWebState() override;
28 void ReturnWebState(web::WebState* web_state) override;
29
30 private:
31 web::BrowserState* browser_state_;
32 // Map of the WebStates currently alive.
33 std::map<web::WebState*, std::unique_ptr<web::WebState>> web_states_;
34 base::WeakPtrFactory<WebStateDispatcherImpl> weak_ptr_factory_;
35 };
36
37 } // namespace dom_distiller
38
39 #endif // IOS_CHROME_BROWSER_DOM_DISTILLER_WEB_STATE_DISPATCHER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698