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

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

Issue 6461024: Revert 74292 - Splits ChromeURLDataManager into 2 chunks:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 10 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 | « chrome/browser/browser_main.cc ('k') | chrome/browser/browser_signin.cc » ('j') | 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_shutdown.h" 5 #include "chrome/browser/browser_shutdown.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 // and then write it to a file to be read at startup. 250 // and then write it to a file to be read at startup.
251 // We can't use prefs since all services are shutdown at this point. 251 // We can't use prefs since all services are shutdown at this point.
252 TimeDelta shutdown_delta = Time::Now() - shutdown_started_; 252 TimeDelta shutdown_delta = Time::Now() - shutdown_started_;
253 std::string shutdown_ms = 253 std::string shutdown_ms =
254 base::Int64ToString(shutdown_delta.InMilliseconds()); 254 base::Int64ToString(shutdown_delta.InMilliseconds());
255 int len = static_cast<int>(shutdown_ms.length()) + 1; 255 int len = static_cast<int>(shutdown_ms.length()) + 1;
256 FilePath shutdown_ms_file = GetShutdownMsPath(); 256 FilePath shutdown_ms_file = GetShutdownMsPath();
257 file_util::WriteFile(shutdown_ms_file, shutdown_ms.c_str(), len); 257 file_util::WriteFile(shutdown_ms_file, shutdown_ms.c_str(), len);
258 } 258 }
259 259
260 UnregisterURLRequestChromeJob();
261
260 #if defined(OS_CHROMEOS) 262 #if defined(OS_CHROMEOS)
261 BrowserList::NotifyAndTerminate(false); 263 BrowserList::NotifyAndTerminate(false);
262 #endif 264 #endif
263 265
264 ChromeURLDataManager::DeleteDataSources(); 266 // Clean up data sources before the UI thread is removed.
267 ChromeURLDataManager* data_manager = ChromeURLDataManager::GetInstance();
268 if (data_manager)
269 data_manager->RemoveAllDataSources();
265 } 270 }
266 271
267 void ReadLastShutdownFile( 272 void ReadLastShutdownFile(
268 ShutdownType type, 273 ShutdownType type,
269 int num_procs, 274 int num_procs,
270 int num_procs_slow) { 275 int num_procs_slow) {
271 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE)); 276 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE));
272 277
273 FilePath shutdown_ms_file = GetShutdownMsPath(); 278 FilePath shutdown_ms_file = GetShutdownMsPath();
274 std::string shutdown_ms_str; 279 std::string shutdown_ms_str;
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 342
338 bool ShuttingDownWithoutClosingBrowsers() { 343 bool ShuttingDownWithoutClosingBrowsers() {
339 #if defined(USE_X11) 344 #if defined(USE_X11)
340 if (GetShutdownType() == browser_shutdown::END_SESSION) 345 if (GetShutdownType() == browser_shutdown::END_SESSION)
341 return true; 346 return true;
342 #endif 347 #endif
343 return false; 348 return false;
344 } 349 }
345 350
346 } // namespace browser_shutdown 351 } // namespace browser_shutdown
OLDNEW
« no previous file with comments | « chrome/browser/browser_main.cc ('k') | chrome/browser/browser_signin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698