Chromium Code Reviews
[email protected] (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Issue 4635007: When an extension is uninstalled, close all desktop notifications from that e... (Closed)

Created:
10 years, 1 month ago by John Gregg
Modified:
9 years ago
CC:
chromium-reviews, Paweł Hajdan Jr., davemoore+watch_chromium.org, ben+cc_chromium.org
Visibility:
Public.

Description

When an extension is uninstalled, close all desktop notifications from that extension. This change also refactors the balloon collection code to remove duplication between chrome and chromeos. Removes some gross removal code which was using fake notifications just to get the right ID. BUG=58266 TEST=open notifications from extension, uninstall extensions Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=65879 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=66571 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=66829

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Patch Set 5 : lint fixes #

Total comments: 20

Patch Set 6 : '' #

Patch Set 7 : '' #

Patch Set 8 : '' #

Total comments: 10

Patch Set 9 : '' #

Total comments: 14

Patch Set 10 : '' #

Patch Set 11 : '' #

Patch Set 12 : '' #

Patch Set 13 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+224 lines, -233 lines) Patch
M chrome/browser/automation/testing_automation_provider.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/chromeos/notifications/balloon_collection_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +10 lines, -9 lines 0 comments Download
M chrome/browser/chromeos/notifications/balloon_collection_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 11 chunks +17 lines, -47 lines 0 comments Download
M chrome/browser/chromeos/notifications/balloon_view.cc View 6 7 8 9 10 11 12 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/chromeos/notifications/desktop_notifications_unittest.h View 7 8 9 10 11 12 4 chunks +1 line, -4 lines 0 comments Download
M chrome/browser/chromeos/notifications/desktop_notifications_unittest.cc View 7 8 9 10 11 12 1 chunk +8 lines, -17 lines 0 comments Download
M chrome/browser/chromeos/notifications/notification_browsertest.cc View 8 9 10 11 12 8 chunks +13 lines, -33 lines 0 comments Download
M chrome/browser/chromeos/notifications/notification_panel.cc View 6 7 8 9 10 11 12 1 chunk +2 lines, -4 lines 0 comments Download
M chrome/browser/chromeos/notifications/system_notification.cc View 6 7 8 9 10 11 12 1 chunk +1 line, -3 lines 0 comments Download
M chrome/browser/cocoa/notifications/balloon_controller.mm View 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/cocoa/notifications/balloon_controller_unittest.mm View 10 11 12 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/gtk/notifications/balloon_view_gtk.cc View 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/notifications/balloon_collection.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +8 lines, -2 lines 0 comments Download
M chrome/browser/notifications/balloon_collection.cc View 1 2 3 4 5 6 7 8 9 10 11 12 7 chunks +28 lines, -31 lines 0 comments Download
M chrome/browser/notifications/balloon_collection_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +10 lines, -16 lines 0 comments Download
M chrome/browser/notifications/balloon_collection_linux.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/notifications/balloon_collection_win.cc View 2 3 4 5 6 7 8 9 10 11 12 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/notifications/desktop_notification_service.h View 1 2 3 4 5 6 7 8 9 10 11 12 3 chunks +7 lines, -4 lines 0 comments Download
M chrome/browser/notifications/desktop_notification_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 6 chunks +32 lines, -13 lines 0 comments Download
M chrome/browser/notifications/desktop_notifications_unittest.h View 4 5 6 7 8 9 10 11 12 3 chunks +2 lines, -5 lines 0 comments Download
M chrome/browser/notifications/desktop_notifications_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +7 lines, -15 lines 0 comments Download
M chrome/browser/notifications/notification.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/notifications/notification.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -4 lines 0 comments Download
M chrome/browser/notifications/notification_options_menu_model.cc View 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/notifications/notification_test_util.h View 4 5 6 7 8 9 10 11 12 5 chunks +19 lines, -4 lines 0 comments Download
M chrome/browser/notifications/notification_ui_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +9 lines, -2 lines 0 comments Download
M chrome/browser/notifications/notification_ui_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +22 lines, -5 lines 0 comments Download
M chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -3 lines 0 comments Download
M chrome/browser/task_manager/task_manager_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/extensions/extension_view.cc View 12 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/location_bar/location_bar_view.cc View 12 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/notifications/balloon_view.cc View 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M chrome/chrome_browser.gypi View 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
John Gregg
for review: oshima for chromeos atwilson for everything else Thanks!
10 years, 1 month ago (2010-11-10 21:18:54 UTC) #1
Andrew T Wilson (Slow)
Looks like a really solid refactoring - I had a few concerns which I noted ...
10 years, 1 month ago (2010-11-11 01:07:44 UTC) #2
tfarina
http://codereview.chromium.org/4635007/diff/76002/chrome/browser/chromeos/notifications/balloon_view.cc File chrome/browser/chromeos/notifications/balloon_view.cc (right): http://codereview.chromium.org/4635007/diff/76002/chrome/browser/chromeos/notifications/balloon_view.cc#newcode303 chrome/browser/chromeos/notifications/balloon_view.cc:303: return balloon_->notification().notification_id() == notification.notification_id(); nit: line > 80 characters ...
10 years, 1 month ago (2010-11-11 12:56:57 UTC) #3
John Gregg
Comments addressed, PTAL http://codereview.chromium.org/4635007/diff/69001/chrome/browser/chromeos/notifications/balloon_collection_impl.cc File chrome/browser/chromeos/notifications/balloon_collection_impl.cc (right): http://codereview.chromium.org/4635007/diff/69001/chrome/browser/chromeos/notifications/balloon_collection_impl.cc#newcode126 chrome/browser/chromeos/notifications/balloon_collection_impl.cc:126: base_.Remove(source); On 2010/11/11 01:07:44, Andrew T ...
10 years, 1 month ago (2010-11-11 18:13:45 UTC) #4
John Gregg
> Also, I notice that notification_types.h declares two notifications: > EXTENSION_UNLOADED and EXTENSION_UNLOADED_DISABLED. I think ...
10 years, 1 month ago (2010-11-11 18:14:47 UTC) #5
oshima
http://codereview.chromium.org/4635007/diff/112002/chrome/browser/chromeos/notifications/desktop_notifications_unittest.cc File chrome/browser/chromeos/notifications/desktop_notifications_unittest.cc (right): http://codereview.chromium.org/4635007/diff/112002/chrome/browser/chromeos/notifications/desktop_notifications_unittest.cc#newcode41 chrome/browser/chromeos/notifications/desktop_notifications_unittest.cc:41: new LoggingNotificationProxy(notification.notification_id())); who deletes this object now? http://codereview.chromium.org/4635007/diff/112002/chrome/browser/notifications/balloon_collection_base.h File ...
10 years, 1 month ago (2010-11-11 19:00:16 UTC) #6
Andrew T Wilson (Slow)
LGTM with minor nits. http://codereview.chromium.org/4635007/diff/112002/chrome/browser/notifications/balloon_collection.h File chrome/browser/notifications/balloon_collection.h (right): http://codereview.chromium.org/4635007/diff/112002/chrome/browser/notifications/balloon_collection.h#newcode54 chrome/browser/notifications/balloon_collection.h:54: // true if anything was ...
10 years, 1 month ago (2010-11-11 21:09:49 UTC) #7
John Gregg
all changes made. the header file inclusions required me to bring in a few other ...
10 years, 1 month ago (2010-11-11 23:17:46 UTC) #8
oshima
LGTM
10 years, 1 month ago (2010-11-12 00:01:25 UTC) #9
evanm
http://build.chromium.org/p/chromium/builders/Interactive%20Tests%20(dbg)/builds/1271 TestInfoBarsCloseOnNewTheme started failing on this change and has failed ever since
10 years, 1 month ago (2010-11-12 03:02:19 UTC) #10
tfarina
10 years, 1 month ago (2010-11-12 11:27:49 UTC) #11
My nits LGTM

Powered by Google App Engine
This is Rietveld 408576698