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

Issue 2239133002: [Offline pages] Downloads UI: Adding bridge for issuing notifications (Closed)

Created:
4 years, 4 months ago by fgorski
Modified:
4 years, 4 months ago
Reviewers:
qinmin, Dmitry Titov
CC:
chromium-reviews, asanka, dewittj+watch_chromium.org, fgorski+watch_chromium.org, romax+watch_chromium.org, petewil+watch_chromium.org, chili+watch_chromium.org, dimich+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@download-notifications
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Offline pages] Downloads UI: Adding bridge for issuing notifications Changes: * Updates DownloadNotifiactionSerivce to include handling of offline pages * Adds openItem and destroy methods to DownloadServiceDelegate (to handle offline pages and prevent memory leaks) * Adds notification bridge for offline pages related downloads (implemented on C++ and Java side) only calls from c++ to Java. * Adds interface to components that will be implemented by the bridge * Updating OPDownloadBridge to issue notification when current page is captured. * Adding copy constructor to DownloadUIItem BUG=630817 Committed: https://crrev.com/9e8c5f4e30270447969f04bfe4d676b6d94f25b9 Cr-Commit-Position: refs/heads/master@{#413214}

Patch Set 1 #

Patch Set 2 : Basic implementation of all notify methods. #

Patch Set 3 : Adding enough information to distinguish download from offline page #

Patch Set 4 : Adding notifying observer of request coordinator #

Patch Set 5 : Fixing build dependencies #

Patch Set 6 : Updating observer and adding ability to open offline page from notification #

Patch Set 7 : Wiring notifications end to end (with async load requests and download button) #

Patch Set 8 : Update to make success notification clickable #

Patch Set 9 : Minimizing the patch to handle direct WC capture on download button #

Total comments: 10

Patch Set 10 : Addressing CR feedback #

Unified diffs Side-by-side diffs Delta from patch set Stats (+405 lines, -34 lines) Patch
M chrome/android/java/src/org/chromium/chrome/browser/download/DownloadBroadcastReceiver.java View 1 2 3 4 5 2 chunks +2 lines, -1 line 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/download/DownloadInfo.java View 1 2 6 chunks +14 lines, -1 line 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/download/DownloadManagerService.java View 1 2 3 4 5 6 7 8 5 chunks +20 lines, -2 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java View 1 2 3 4 5 6 7 8 9 12 chunks +50 lines, -17 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/download/DownloadServiceDelegate.java View 1 2 3 4 5 6 7 8 1 chunk +9 lines, -0 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/download/SystemDownloadNotifier.java View 1 2 3 4 5 2 chunks +6 lines, -6 lines 0 comments Download
M chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageDownloadBridge.java View 1 2 3 4 5 6 7 8 9 1 chunk +6 lines, -0 lines 0 comments Download
A chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageNotificationBridge.java View 1 2 3 4 5 6 7 8 9 1 chunk +136 lines, -0 lines 0 comments Download
M chrome/android/java_sources.gni View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M chrome/android/javatests/src/org/chromium/chrome/browser/download/DownloadNotificationServiceTest.java View 1 2 3 4 5 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/android/offline_pages/downloads/offline_page_download_bridge.h View 1 2 3 4 5 6 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/android/offline_pages/downloads/offline_page_download_bridge.cc View 1 2 3 4 5 6 7 8 9 3 chunks +17 lines, -3 lines 0 comments Download
A chrome/browser/android/offline_pages/downloads/offline_page_notification_bridge.h View 1 2 3 4 5 6 7 8 1 chunk +34 lines, -0 lines 0 comments Download
A chrome/browser/android/offline_pages/downloads/offline_page_notification_bridge.cc View 1 2 3 4 5 6 7 8 1 chunk +66 lines, -0 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 2 chunks +3 lines, -0 lines 0 comments Download
M components/offline_pages.gypi View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M components/offline_pages/downloads/BUILD.gn View 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M components/offline_pages/downloads/download_ui_item.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M components/offline_pages/downloads/download_ui_item.cc View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -0 lines 0 comments Download
A components/offline_pages/downloads/offline_page_download_notifier.h View 1 chunk +26 lines, -0 lines 0 comments Download

Messages

Total messages: 45 (36 generated)
fgorski
This patch has ways to go, but demonstrates general idea of how to interact with ...
4 years, 4 months ago (2016-08-11 23:08:36 UTC) #2
Dmitry Titov
looks ok so far
4 years, 4 months ago (2016-08-12 20:04:10 UTC) #11
fgorski
ptal https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageDownloadBridge.java File chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageDownloadBridge.java (right): https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageDownloadBridge.java#newcode72 chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageDownloadBridge.java:72: return createDefault(); these 4 lines to be removed
4 years, 4 months ago (2016-08-18 22:59:51 UTC) #31
Dmitry Titov
lgtm I think request_coordinator.[h,cc] changes are unrelated to this patch (although seem useful) - can ...
4 years, 4 months ago (2016-08-18 23:30:18 UTC) #32
qinmin
lgtm % comments https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java File chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java (right): https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java#newcode497 chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java:497: ? DownloadSharedPreferenceEntry.ITEM_TYPE_OFFLINE_PAGE fix indentation https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/offlinepages/downloads/OfflinePageNotificationBridge.java File ...
4 years, 4 months ago (2016-08-18 23:46:59 UTC) #33
fgorski
comments addressed. running bots now. https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java File chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java (right): https://codereview.chromium.org/2239133002/diff/160001/chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java#newcode497 chrome/android/java/src/org/chromium/chrome/browser/download/DownloadNotificationService.java:497: ? DownloadSharedPreferenceEntry.ITEM_TYPE_OFFLINE_PAGE On 2016/08/18 ...
4 years, 4 months ago (2016-08-19 17:03:24 UTC) #36
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2239133002/180001
4 years, 4 months ago (2016-08-19 18:33:59 UTC) #41
commit-bot: I haz the power
Committed patchset #10 (id:180001)
4 years, 4 months ago (2016-08-19 19:49:37 UTC) #43
commit-bot: I haz the power
4 years, 4 months ago (2016-08-19 19:51:51 UTC) #45
Message was sent while issue was closed.
Patchset 10 (id:??) landed as
https://crrev.com/9e8c5f4e30270447969f04bfe4d676b6d94f25b9
Cr-Commit-Position: refs/heads/master@{#413214}

Powered by Google App Engine
This is Rietveld 408576698