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

Issue 593563002: For Mac, add AppListViewDelegateObserver::OnShutdown (Closed)

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

Description

For Mac, add AppListViewDelegateObserver::OnShutdown; deflake tests We used to just leak everything on Mac. Since r295194, we clean up references to Profiles being deleted, in Chrome's AppListViewDelegate. This has caught out the Mac app list trying to access stuff it shouldn't if Cocoa is still drawing it while Chrome is shutting down. Tests started failing flakily. This CL adds AppListViewDelegateObserver::OnShutdown to that Chrome's AppListViewDelegate can notify the AppListView that it's shutting down. On Views platforms, the Widget is just closed (which also happens just after the chrome::NOTIFICATION_APP_TERMINATING broadcast). However, (a) Cocoa doesn't have a `CloseAllSecondaryWidgets` call to trigger this and (b) just closing the NSWindow isn't usually enough on Cocoa to avoid accessing C++ objects due to reference counting. We could also go through the platform-specific AppListService (e.g. by passing in the AppListService that creates a Chrome AppListViewDelegate), but this seemed neater. This de-flakes a bunch of applist tests on Mac. The Mac-specific ShowAppListUsingShim test is also augmented with extra checks for the OnShutdown stuff. BUG=415264 TEST=AppListServiceMacInteractiveTest.ShowAppListUsingShim, AppListServiceInteractiveTest.* Committed: https://crrev.com/a40c605b9f633c7e2022be24aff5705ef0f89777 Cr-Commit-Position: refs/heads/master@{#296363}

Patch Set 1 #

Patch Set 2 : Incorporate crrev/589333002 for trybots #

Patch Set 3 : rebase to matser #

Patch Set 4 : with SwitchAppListProfilesDuringSearch enabled, for bots #

Patch Set 5 : disable test on mac #

Patch Set 6 : cl format, nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+77 lines, -12 lines) Patch
M chrome/browser/ui/app_list/app_list_service_interactive_uitest.cc View 1 2 3 4 1 chunk +12 lines, -6 lines 0 comments Download
M chrome/browser/ui/app_list/app_list_service_mac.h View 1 2 3 4 5 2 chunks +5 lines, -0 lines 0 comments Download
M chrome/browser/ui/app_list/app_list_service_mac_interactive_uitest.mm View 1 2 3 4 5 6 chunks +39 lines, -4 lines 0 comments Download
M chrome/browser/ui/app_list/app_list_view_delegate.cc View 1 1 chunk +3 lines, -0 lines 0 comments Download
M ui/app_list/app_list_item_list.h View 1 1 chunk +1 line, -1 line 0 comments Download
M ui/app_list/app_list_model.h View 1 chunk +1 line, -1 line 0 comments Download
M ui/app_list/app_list_view_delegate_observer.h View 1 chunk +5 lines, -0 lines 0 comments Download
M ui/app_list/cocoa/app_list_view_controller.mm View 2 chunks +5 lines, -0 lines 0 comments Download
M ui/app_list/views/app_list_view.h View 1 chunk +1 line, -0 lines 0 comments Download
M ui/app_list/views/app_list_view.cc View 1 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 9 (4 generated)
tapted
6 years, 3 months ago (2014-09-24 06:56:29 UTC) #4
jackhou1
lgtm
6 years, 3 months ago (2014-09-24 07:11:40 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/593563002/140001
6 years, 3 months ago (2014-09-24 07:15:29 UTC) #7
commit-bot: I haz the power
Committed patchset #6 (id:140001) as e208b90a52559e73ef05a322f5ee16221aca0bdb
6 years, 3 months ago (2014-09-24 07:40:33 UTC) #8
commit-bot: I haz the power
6 years, 3 months ago (2014-09-24 07:41:24 UTC) #9
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/a40c605b9f633c7e2022be24aff5705ef0f89777
Cr-Commit-Position: refs/heads/master@{#296363}

Powered by Google App Engine
This is Rietveld 408576698