| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
| 8 #include "base/clipboard.h" | 8 #include "base/clipboard.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/file_util.h" | 10 #include "base/file_util.h" |
| (...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 441 void BrowserProcessImpl::CreateGoogleURLTracker() { | 441 void BrowserProcessImpl::CreateGoogleURLTracker() { |
| 442 DCHECK(google_url_tracker_.get() == NULL); | 442 DCHECK(google_url_tracker_.get() == NULL); |
| 443 scoped_ptr<GoogleURLTracker> google_url_tracker(new GoogleURLTracker); | 443 scoped_ptr<GoogleURLTracker> google_url_tracker(new GoogleURLTracker); |
| 444 google_url_tracker_.swap(google_url_tracker); | 444 google_url_tracker_.swap(google_url_tracker); |
| 445 } | 445 } |
| 446 | 446 |
| 447 // The BrowserProcess object must outlive the file thread so we use traits | 447 // The BrowserProcess object must outlive the file thread so we use traits |
| 448 // which don't do any management. | 448 // which don't do any management. |
| 449 template <> | 449 template <> |
| 450 struct RunnableMethodTraits<BrowserProcessImpl> { | 450 struct RunnableMethodTraits<BrowserProcessImpl> { |
| 451 static void RetainCallee(BrowserProcessImpl*) {} | 451 void RetainCallee(BrowserProcessImpl*) {} |
| 452 static void ReleaseCallee(BrowserProcessImpl*) {} | 452 void ReleaseCallee(BrowserProcessImpl*) {} |
| 453 }; | 453 }; |
| 454 | 454 |
| 455 void BrowserProcessImpl::CheckForInspectorFiles() { | 455 void BrowserProcessImpl::CheckForInspectorFiles() { |
| 456 file_thread()->message_loop()->PostTask | 456 file_thread()->message_loop()->PostTask |
| 457 (FROM_HERE, | 457 (FROM_HERE, |
| 458 NewRunnableMethod(this, &BrowserProcessImpl::DoInspectorFilesCheck)); | 458 NewRunnableMethod(this, &BrowserProcessImpl::DoInspectorFilesCheck)); |
| 459 } | 459 } |
| 460 | 460 |
| 461 #if defined(IPC_MESSAGE_LOG_ENABLED) | 461 #if defined(IPC_MESSAGE_LOG_ENABLED) |
| 462 | 462 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 505 DCHECK(file_thread_->message_loop() == MessageLoop::current()); | 505 DCHECK(file_thread_->message_loop() == MessageLoop::current()); |
| 506 bool result = false; | 506 bool result = false; |
| 507 | 507 |
| 508 FilePath inspector_dir; | 508 FilePath inspector_dir; |
| 509 if (PathService::Get(chrome::DIR_INSPECTOR, &inspector_dir)) { | 509 if (PathService::Get(chrome::DIR_INSPECTOR, &inspector_dir)) { |
| 510 result = file_util::PathExists(inspector_dir); | 510 result = file_util::PathExists(inspector_dir); |
| 511 } | 511 } |
| 512 | 512 |
| 513 have_inspector_files_ = result; | 513 have_inspector_files_ = result; |
| 514 } | 514 } |
| OLD | NEW |