| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_H_ | 5 #ifndef COMPONENTS_DOM_DISTILLER_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_H_ |
| 6 #define COMPONENTS_DOM_DISTILLER_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_H_ | 6 #define COMPONENTS_DOM_DISTILLER_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 void StartDataRequest( | 35 void StartDataRequest( |
| 36 const std::string& path, | 36 const std::string& path, |
| 37 int render_process_id, | 37 int render_process_id, |
| 38 int render_frame_id, | 38 int render_frame_id, |
| 39 const content::URLDataSource::GotDataCallback& callback) override; | 39 const content::URLDataSource::GotDataCallback& callback) override; |
| 40 std::string GetMimeType(const std::string& path) const override; | 40 std::string GetMimeType(const std::string& path) const override; |
| 41 bool ShouldServiceRequest(const net::URLRequest* request) const override; | 41 bool ShouldServiceRequest(const net::URLRequest* request) const override; |
| 42 void WillServiceRequest(const net::URLRequest* request, | 42 void WillServiceRequest(const net::URLRequest* request, |
| 43 std::string* path) const override; | 43 std::string* path) const override; |
| 44 std::string GetContentSecurityPolicyStyleSrc() const override; | 44 std::string GetContentSecurityPolicyStyleSrc() const override; |
| 45 std::string GetContentSecurityPolicyFrameSrc() const override; | 45 std::string GetContentSecurityPolicyChildSrc() const override; |
| 46 | 46 |
| 47 private: | 47 private: |
| 48 friend class DomDistillerViewerSourceTest; | 48 friend class DomDistillerViewerSourceTest; |
| 49 | 49 |
| 50 // The scheme this URLDataSource is hosted under. | 50 // The scheme this URLDataSource is hosted under. |
| 51 std::string scheme_; | 51 std::string scheme_; |
| 52 | 52 |
| 53 // The service which contains all the functionality needed to interact with | 53 // The service which contains all the functionality needed to interact with |
| 54 // the list of articles. | 54 // the list of articles. |
| 55 DomDistillerServiceInterface* dom_distiller_service_; | 55 DomDistillerServiceInterface* dom_distiller_service_; |
| 56 | 56 |
| 57 // An object for accessing chrome-specific UI controls including external | 57 // An object for accessing chrome-specific UI controls including external |
| 58 // feedback and opening the distiller settings. | 58 // feedback and opening the distiller settings. |
| 59 std::unique_ptr<DistillerUIHandle> distiller_ui_handle_; | 59 std::unique_ptr<DistillerUIHandle> distiller_ui_handle_; |
| 60 | 60 |
| 61 DISALLOW_COPY_AND_ASSIGN(DomDistillerViewerSource); | 61 DISALLOW_COPY_AND_ASSIGN(DomDistillerViewerSource); |
| 62 }; | 62 }; |
| 63 | 63 |
| 64 } // namespace dom_distiller | 64 } // namespace dom_distiller |
| 65 | 65 |
| 66 #endif // COMPONENTS_DOM_DISTILLER_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_
H_ | 66 #endif // COMPONENTS_DOM_DISTILLER_CONTENT_BROWSER_DOM_DISTILLER_VIEWER_SOURCE_
H_ |
| OLD | NEW |