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

Issue 580713002: Close the App Info Dialog if the app or profile becomes invalid (Closed)

Created:
6 years, 3 months ago by sashab
Modified:
6 years, 2 months ago
Reviewers:
tapted, Matt Giuca
CC:
chromium-reviews, tfarina, chrome-apps-syd-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Close the App Info Dialog if the app or profile becomes invalid Adds the App Info dialog as a profile observer, and closes the dialog if the current profile is destroyed. Also, if the App Info Dialog is open for an app and it is uninstalled asynchronously, close the dialog. This prevents errors where actions can still be taken on the app even though it's been removed. BUG=384999, 408473 TEST=While the App Info Dialog is open for an app, uninstall the app. The dialog and app list should close. TEST=While the App Info Dialog is open, destroy the profile the app list is open for. The dialog and app list should close. Committed: https://crrev.com/58aac678723b1e9c82e2cf5572180b6923d19fc4 Cr-Commit-Position: refs/heads/master@{#297605}

Patch Set 1 #

Total comments: 14

Patch Set 2 : Feedback & added unit test #

Patch Set 3 : Merged in uninstall observer #

Total comments: 16

Patch Set 4 : Partial review progress #

Patch Set 5 : Review feedback + TODO to stop using the deprecated TestBrowserThread #

Total comments: 12

Patch Set 6 : Small changes #

Patch Set 7 : Added a TestUserManager to fix tests on ChromeOS #

Patch Set 8 : Rebase #

Patch Set 9 : Aded a test ChromeOS settings and a test Device Settings Service for ChromeOS #

Patch Set 10 : Changed test to extend AshTestBase and create a widget without WidgetTest. #

Total comments: 6

Patch Set 11 : Small fixes #

Messages

Total messages: 30 (9 generated)
sashab
Feel free to pass this on if you don't have time to look at it.
6 years, 3 months ago (2014-09-18 00:49:13 UTC) #2
tapted
can you add a test? https://codereview.chromium.org/580713002/diff/1/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc (right): https://codereview.chromium.org/580713002/diff/1/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc#newcode105 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc:105: StartObservingExtensionRegistry(); adding observers in ...
6 years, 3 months ago (2014-09-18 01:06:32 UTC) #3
Matt Giuca
Also, can you add a TEST= line to the CL description so this gets added ...
6 years, 3 months ago (2014-09-18 01:30:57 UTC) #4
Matt Giuca
Drive-by. https://codereview.chromium.org/580713002/diff/1/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc (right): https://codereview.chromium.org/580713002/diff/1/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc#newcode138 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc:138: GetWidget()->Close(); Can you write a new method Close() ...
6 years, 3 months ago (2014-09-18 01:33:53 UTC) #6
sashab
Unfortunately the async profile stuff is still needed, although I'm happy to merge it into ...
6 years, 3 months ago (2014-09-18 03:00:01 UTC) #7
sashab
Getting all kinds of errors unless I keep track of the extension registry. I think ...
6 years, 3 months ago (2014-09-18 03:54:16 UTC) #8
tapted
https://codereview.chromium.org/580713002/diff/40001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc (right): https://codereview.chromium.org/580713002/diff/40001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc#newcode111 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc:111: chrome::NOTIFICATION_PROFILE_DESTROYED, Let's try it without this: i'm fairly confident ...
6 years, 3 months ago (2014-09-18 05:20:19 UTC) #9
sashab
https://codereview.chromium.org/580713002/diff/40001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc (right): https://codereview.chromium.org/580713002/diff/40001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc#newcode111 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc:111: chrome::NOTIFICATION_PROFILE_DESTROYED, On 2014/09/18 05:20:18, tapted wrote: > Let's try ...
6 years, 3 months ago (2014-09-22 05:41:02 UTC) #10
tapted
lgtm with a few changes - sorry for the lag! This one got inbox-buried.. https://codereview.chromium.org/580713002/diff/70001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc ...
6 years, 3 months ago (2014-09-23 07:40:36 UTC) #11
sashab
https://codereview.chromium.org/580713002/diff/70001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc (right): https://codereview.chromium.org/580713002/diff/70001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc#newcode10 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views.cc:10: #include "chrome/browser/chrome_notification_types.h" On 2014/09/23 07:40:36, tapted wrote: > nit: ...
6 years, 3 months ago (2014-09-24 01:15:45 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/580713002/90001
6 years, 3 months ago (2014-09-24 01:16:53 UTC) #14
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator on tryserver.chromium.mac (http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator/builds/17892) ios_rel_device_ninja on tryserver.chromium.mac (http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_rel_device_ninja/builds/12585)
6 years, 3 months ago (2014-09-24 01:20:41 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/580713002/90001
6 years, 3 months ago (2014-09-25 00:26:26 UTC) #18
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel_swarming/builds/17718)
6 years, 3 months ago (2014-09-25 01:47:36 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/580713002/90001
6 years, 2 months ago (2014-09-25 20:53:20 UTC) #22
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel_swarming on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel_swarming/builds/18043)
6 years, 2 months ago (2014-09-25 22:45:09 UTC) #24
tapted
https://codereview.chromium.org/580713002/diff/170001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc File chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc (right): https://codereview.chromium.org/580713002/diff/170001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc#newcode16 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc:16: #include "ui/views/test/widget_test.h" remove? https://codereview.chromium.org/580713002/diff/170001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc#newcode31 chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc:31: class TestModalDialogDelegate : public ...
6 years, 2 months ago (2014-10-01 01:41:35 UTC) #25
sashab
Small fixes :) Should all be OK now. tapted ptal if you like :) https://codereview.chromium.org/580713002/diff/170001/chrome/browser/ui/views/apps/app_info_dialog/app_info_dialog_views_unittest.cc ...
6 years, 2 months ago (2014-10-01 03:34:18 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/580713002/190001
6 years, 2 months ago (2014-10-01 07:24:43 UTC) #28
commit-bot: I haz the power
Committed patchset #11 (id:190001) as b835ca5671047e120b6c65a20f21c2354a644ef5
6 years, 2 months ago (2014-10-01 07:29:06 UTC) #29
commit-bot: I haz the power
6 years, 2 months ago (2014-10-01 07:29:49 UTC) #30
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/58aac678723b1e9c82e2cf5572180b6923d19fc4
Cr-Commit-Position: refs/heads/master@{#297605}

Powered by Google App Engine
This is Rietveld 408576698