OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/browser_process_impl.h" | 5 #include "chrome/browser/browser_process_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <map> | 10 #include <map> |
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
304 // that URLFetcher operation before going away.) | 304 // that URLFetcher operation before going away.) |
305 metrics_services_manager_.reset(); | 305 metrics_services_manager_.reset(); |
306 intranet_redirect_detector_.reset(); | 306 intranet_redirect_detector_.reset(); |
307 if (safe_browsing_service_.get()) | 307 if (safe_browsing_service_.get()) |
308 safe_browsing_service()->ShutDown(); | 308 safe_browsing_service()->ShutDown(); |
309 network_time_tracker_.reset(); | 309 network_time_tracker_.reset(); |
310 #if BUILDFLAG(ENABLE_PLUGINS) | 310 #if BUILDFLAG(ENABLE_PLUGINS) |
311 plugins_resource_service_.reset(); | 311 plugins_resource_service_.reset(); |
312 #endif | 312 #endif |
313 | 313 |
| 314 // Clear notification bridge explicitly, since it may consume resources for |
| 315 // notifications that haven't been shown. For example, on Windows 10 we'd use |
| 316 // store temporary images files. |
| 317 notification_bridge_.reset(); |
| 318 |
314 // Need to clear the desktop notification balloons before the io_thread_ and | 319 // Need to clear the desktop notification balloons before the io_thread_ and |
315 // before the profiles, since if there are any still showing we will access | 320 // before the profiles, since if there are any still showing we will access |
316 // those things during teardown. | 321 // those things during teardown. |
317 notification_ui_manager_.reset(); | 322 notification_ui_manager_.reset(); |
318 | 323 |
319 // The SupervisedUserWhitelistInstaller observes the ProfileAttributesStorage, | 324 // The SupervisedUserWhitelistInstaller observes the ProfileAttributesStorage, |
320 // so it needs to be shut down before the ProfileManager. | 325 // so it needs to be shut down before the ProfileManager. |
321 supervised_user_whitelist_installer_.reset(); | 326 supervised_user_whitelist_installer_.reset(); |
322 | 327 |
323 // Debugger must be cleaned up before ProfileManager. | 328 // Debugger must be cleaned up before ProfileManager. |
(...skipping 1103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1427 } | 1432 } |
1428 | 1433 |
1429 void BrowserProcessImpl::OnAutoupdateTimer() { | 1434 void BrowserProcessImpl::OnAutoupdateTimer() { |
1430 if (CanAutorestartForUpdate()) { | 1435 if (CanAutorestartForUpdate()) { |
1431 DLOG(WARNING) << "Detected update. Restarting browser."; | 1436 DLOG(WARNING) << "Detected update. Restarting browser."; |
1432 RestartBackgroundInstance(); | 1437 RestartBackgroundInstance(); |
1433 } | 1438 } |
1434 } | 1439 } |
1435 | 1440 |
1436 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) | 1441 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) |
OLD | NEW |