| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // This class pairs with DownloadController on Java side to forward requests | 5 // This class pairs with DownloadController on Java side to forward requests |
| 6 // for GET downloads to the current DownloadListener. POST downloads are | 6 // for GET downloads to the current DownloadListener. POST downloads are |
| 7 // handled on the native side. | 7 // handled on the native side. |
| 8 // | 8 // |
| 9 // Both classes are Singleton classes. C++ object owns Java object. | 9 // Both classes are Singleton classes. C++ object owns Java object. |
| 10 // | 10 // |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 // Default copy constructor is used for passing this struct by value. | 69 // Default copy constructor is used for passing this struct by value. |
| 70 }; | 70 }; |
| 71 struct JavaObject; | 71 struct JavaObject; |
| 72 friend struct DefaultSingletonTraits<DownloadControllerAndroidImpl>; | 72 friend struct DefaultSingletonTraits<DownloadControllerAndroidImpl>; |
| 73 DownloadControllerAndroidImpl(); | 73 DownloadControllerAndroidImpl(); |
| 74 virtual ~DownloadControllerAndroidImpl(); | 74 virtual ~DownloadControllerAndroidImpl(); |
| 75 | 75 |
| 76 // DownloadControllerAndroid implementation. | 76 // DownloadControllerAndroid implementation. |
| 77 virtual void CreateGETDownload(RenderViewHost* source, | 77 virtual void CreateGETDownload(RenderViewHost* source, |
| 78 int request_id) OVERRIDE; | 78 int request_id) OVERRIDE; |
| 79 virtual void OnPostDownloadStarted(WebContents* web_contents, | 79 virtual void OnPostDownloadStarted(DownloadItem* download_item) OVERRIDE; |
| 80 DownloadItem* download_item) OVERRIDE; | |
| 81 | 80 |
| 82 // DownloadItem::Observer interface. | 81 // DownloadItem::Observer interface. |
| 83 virtual void OnDownloadUpdated(DownloadItem* item) OVERRIDE; | 82 virtual void OnDownloadUpdated(DownloadItem* item) OVERRIDE; |
| 84 virtual void OnDownloadOpened(DownloadItem* item) OVERRIDE; | 83 virtual void OnDownloadOpened(DownloadItem* item) OVERRIDE; |
| 85 | 84 |
| 86 | 85 |
| 87 void PrepareDownloadInfo(const GlobalRequestID& global_id, | 86 void PrepareDownloadInfo(const GlobalRequestID& global_id, |
| 88 int render_process_id, | 87 int render_process_id, |
| 89 int render_view_id); | 88 int render_view_id); |
| 90 | 89 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 118 JavaObject* GetJavaObject(); | 117 JavaObject* GetJavaObject(); |
| 119 | 118 |
| 120 JavaObject* java_object_; | 119 JavaObject* java_object_; |
| 121 | 120 |
| 122 DISALLOW_COPY_AND_ASSIGN(DownloadControllerAndroidImpl); | 121 DISALLOW_COPY_AND_ASSIGN(DownloadControllerAndroidImpl); |
| 123 }; | 122 }; |
| 124 | 123 |
| 125 } // namespace content | 124 } // namespace content |
| 126 | 125 |
| 127 #endif // CONTENT_BROWSER_ANDROID_DOWNLOAD_CONTROLLER_ANDROID_IMPL_H_ | 126 #endif // CONTENT_BROWSER_ANDROID_DOWNLOAD_CONTROLLER_ANDROID_IMPL_H_ |
| OLD | NEW |