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

Side by Side Diff: chrome/browser/browser_process_impl.cc

Issue 3051029: Shutdown the notification UI manager before the notifications service, as the... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 <map> 7 #include <map>
8 8
9 #include "app/clipboard/clipboard.h" 9 #include "app/clipboard/clipboard.h"
10 #include "app/l10n_util.h" 10 #include "app/l10n_util.h"
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 resource_dispatcher_host_.reset(); 186 resource_dispatcher_host_.reset();
187 187
188 // Wait for the pending print jobs to finish. 188 // Wait for the pending print jobs to finish.
189 print_job_manager_->OnQuit(); 189 print_job_manager_->OnQuit();
190 print_job_manager_.reset(); 190 print_job_manager_.reset();
191 191
192 // Destroy TabCloseableStateWatcher before NotificationService since the 192 // Destroy TabCloseableStateWatcher before NotificationService since the
193 // former registers for notifications. 193 // former registers for notifications.
194 tab_closeable_state_watcher_.reset(); 194 tab_closeable_state_watcher_.reset();
195 195
196 // Destroy NotificationUIManager before NotificationService is shut down.
197 notification_ui_manager_.reset();
198
196 // Now OK to destroy NotificationService. 199 // Now OK to destroy NotificationService.
197 main_notification_service_.reset(); 200 main_notification_service_.reset();
198 201
199 // Prior to clearing local state, we want to complete tasks pending 202 // Prior to clearing local state, we want to complete tasks pending
200 // on the db thread too. 203 // on the db thread too.
201 db_thread_.reset(); 204 db_thread_.reset();
202 205
203 // At this point, no render process exist and the file, io, db, and 206 // At this point, no render process exist and the file, io, db, and
204 // webkit threads in this process have all terminated, so it's safe 207 // webkit threads in this process have all terminated, so it's safe
205 // to access local state data such as cookies, database, or local storage. 208 // to access local state data such as cookies, database, or local storage.
(...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after
762 } 765 }
763 766
764 void BrowserProcessImpl::OnAutoupdateTimer() { 767 void BrowserProcessImpl::OnAutoupdateTimer() {
765 if (CanAutorestartForUpdate()) { 768 if (CanAutorestartForUpdate()) {
766 DLOG(WARNING) << "Detected update. Restarting browser."; 769 DLOG(WARNING) << "Detected update. Restarting browser.";
767 RestartPersistentInstance(); 770 RestartPersistentInstance();
768 } 771 }
769 } 772 }
770 773
771 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) 774 #endif // (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698