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

Issue 2620613006: Check if a PWA is installed before checking the service worker and icon. (Closed)

Created:
3 years, 11 months ago by dominickn
Modified:
3 years, 11 months ago
Reviewers:
benwells
CC:
chromium-reviews, dominickn+watch_chromium.org, pkotwicz+watch_chromium.org, zpeng+watch_chromium.org, chrome-apps-syd-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Check if a PWA is installed before checking the service worker and icon. This CL reorganises the app banner validity checking to avoid the asynchronous service worker check and app icon download if the site being checked should not be permitted to show a banner. This may happen if the banner was shown and dismissed / ignored recently, or if the PWA has already been installed. This requires a slight reorganisation in the code as the validity check can only be run after the manifest is downloaded, or after native app data has been fetched if we are checking a native app banner. BUG=667073 Review-Url: https://codereview.chromium.org/2620613006 Cr-Commit-Position: refs/heads/master@{#443826} Committed: https://chromium.googlesource.com/chromium/src/+/a8f5781bcfc7c13294895aa12205d81c3e102a82

Patch Set 1 #

Patch Set 2 : Add lost metrics back #

Total comments: 4

Patch Set 3 : NOTREACHED #

Patch Set 4 : Add missing enum value #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -51 lines) Patch
M chrome/browser/android/banners/app_banner_manager_android.cc View 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/banners/app_banner_manager.h View 2 chunks +5 lines, -3 lines 0 comments Download
M chrome/browser/banners/app_banner_manager.cc View 1 2 3 3 chunks +32 lines, -40 lines 0 comments Download
M chrome/browser/banners/app_banner_settings_helper.cc View 1 2 chunks +1 line, -8 lines 0 comments Download

Messages

Total messages: 43 (30 generated)
dominickn
PTAL, thanks! https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc File chrome/browser/banners/app_banner_manager.cc (left): https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc#oldcode471 chrome/browser/banners/app_banner_manager.cc:471: case INSUFFICIENT_ENGAGEMENT: ShouldShowBanner() will never return INSUFFICIENT_ENGAGEMENT ...
3 years, 11 months ago (2017-01-10 22:51:59 UTC) #11
benwells
lgtm with one little thing https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc File chrome/browser/banners/app_banner_manager.cc (right): https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc#newcode465 chrome/browser/banners/app_banner_manager.cc:465: break; Could this break ...
3 years, 11 months ago (2017-01-13 06:04:27 UTC) #12
dominickn
Thanks! https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc File chrome/browser/banners/app_banner_manager.cc (right): https://codereview.chromium.org/2620613006/diff/40001/chrome/browser/banners/app_banner_manager.cc#newcode465 chrome/browser/banners/app_banner_manager.cc:465: break; On 2017/01/13 06:04:27, benwells wrote: > Could ...
3 years, 11 months ago (2017-01-13 06:11:21 UTC) #15
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/2620613006/60001
3 years, 11 months ago (2017-01-13 06:12:49 UTC) #19
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/99872)
3 years, 11 months ago (2017-01-13 06:57:28 UTC) #21
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/2620613006/60001
3 years, 11 months ago (2017-01-13 07:00:46 UTC) #23
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/99883)
3 years, 11 months ago (2017-01-13 07:44:01 UTC) #25
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/2620613006/60001
3 years, 11 months ago (2017-01-13 07:47:16 UTC) #27
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/99895)
3 years, 11 months ago (2017-01-13 08:35:32 UTC) #29
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/2620613006/60001
3 years, 11 months ago (2017-01-15 22:56:22 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/100755)
3 years, 11 months ago (2017-01-15 23:41:11 UTC) #33
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/2620613006/80001
3 years, 11 months ago (2017-01-16 01:47:45 UTC) #40
commit-bot: I haz the power
3 years, 11 months ago (2017-01-16 01:52:54 UTC) #43
Message was sent while issue was closed.
Committed patchset #4 (id:80001) as
https://chromium.googlesource.com/chromium/src/+/a8f5781bcfc7c13294895aa12205...

Powered by Google App Engine
This is Rietveld 408576698