| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ | 5 #ifndef CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ |
| 6 #define CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ | 6 #define CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 void OnUploadProgress(uint64_t position, uint64_t size) override; | 39 void OnUploadProgress(uint64_t position, uint64_t size) override; |
| 40 bool OnReceivedRedirect(const net::RedirectInfo& redirect_info, | 40 bool OnReceivedRedirect(const net::RedirectInfo& redirect_info, |
| 41 const content::ResourceResponseInfo& info) override; | 41 const content::ResourceResponseInfo& info) override; |
| 42 void OnReceivedResponse(const content::ResourceResponseInfo& info) override; | 42 void OnReceivedResponse(const content::ResourceResponseInfo& info) override; |
| 43 void OnDownloadedData(int len, int encoded_data_length) override {} | 43 void OnDownloadedData(int len, int encoded_data_length) override {} |
| 44 void OnReceivedData(std::unique_ptr<ReceivedData> data) override; | 44 void OnReceivedData(std::unique_ptr<ReceivedData> data) override; |
| 45 void OnCompletedRequest(int error_code, | 45 void OnCompletedRequest(int error_code, |
| 46 bool was_ignored_by_handler, | 46 bool was_ignored_by_handler, |
| 47 bool stale_copy_in_cache, | 47 bool stale_copy_in_cache, |
| 48 const base::TimeTicks& completion_time, | 48 const base::TimeTicks& completion_time, |
| 49 int64_t total_transfer_size) override; | 49 int64_t total_transfer_size, |
| 50 int64_t encoded_body_size) override; |
| 50 | 51 |
| 51 private: | 52 private: |
| 52 friend class ExtensionLocalizationPeerTest; | 53 friend class ExtensionLocalizationPeerTest; |
| 53 | 54 |
| 54 // Use CreateExtensionLocalizationPeer to create an instance. | 55 // Use CreateExtensionLocalizationPeer to create an instance. |
| 55 ExtensionLocalizationPeer(std::unique_ptr<content::RequestPeer> peer, | 56 ExtensionLocalizationPeer(std::unique_ptr<content::RequestPeer> peer, |
| 56 IPC::Sender* message_sender, | 57 IPC::Sender* message_sender, |
| 57 const GURL& request_url); | 58 const GURL& request_url); |
| 58 | 59 |
| 59 // Loads message catalogs, and replaces all __MSG_some_name__ templates within | 60 // Loads message catalogs, and replaces all __MSG_some_name__ templates within |
| (...skipping 14 matching lines...) Expand all Loading... |
| 74 std::string data_; | 75 std::string data_; |
| 75 | 76 |
| 76 // Original request URL. | 77 // Original request URL. |
| 77 GURL request_url_; | 78 GURL request_url_; |
| 78 | 79 |
| 79 private: | 80 private: |
| 80 DISALLOW_COPY_AND_ASSIGN(ExtensionLocalizationPeer); | 81 DISALLOW_COPY_AND_ASSIGN(ExtensionLocalizationPeer); |
| 81 }; | 82 }; |
| 82 | 83 |
| 83 #endif // CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ | 84 #endif // CHROME_RENDERER_EXTENSIONS_EXTENSION_LOCALIZATION_PEER_H_ |
| OLD | NEW |