| 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/chrome_browser_main_linux.h" | 5 #include "chrome/browser/chrome_browser_main_linux.h" |
| 6 | 6 |
| 7 #include <fontconfig/fontconfig.h> | 7 #include <fontconfig/fontconfig.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 | 55 |
| 56 media::AudioManager::SetGlobalAppName( | 56 media::AudioManager::SetGlobalAppName( |
| 57 l10n_util::GetStringUTF8(IDS_SHORT_PRODUCT_NAME)); | 57 l10n_util::GetStringUTF8(IDS_SHORT_PRODUCT_NAME)); |
| 58 | 58 |
| 59 #if !defined(OS_CHROMEOS) | 59 #if !defined(OS_CHROMEOS) |
| 60 // Forward to os_crypt the flag to use a specific password store. | 60 // Forward to os_crypt the flag to use a specific password store. |
| 61 OSCrypt::SetStore( | 61 OSCrypt::SetStore( |
| 62 parsed_command_line().GetSwitchValueASCII(switches::kPasswordStore)); | 62 parsed_command_line().GetSwitchValueASCII(switches::kPasswordStore)); |
| 63 // Forward the product name | 63 // Forward the product name |
| 64 OSCrypt::SetProductName(l10n_util::GetStringUTF8(IDS_PRODUCT_NAME)); | 64 OSCrypt::SetProductName(l10n_util::GetStringUTF8(IDS_PRODUCT_NAME)); |
| 65 // OSCrypt may target keyring, which requires calls from the main thread. |
| 66 scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner( |
| 67 content::BrowserThread::GetTaskRunnerForThread( |
| 68 content::BrowserThread::UI)); |
| 69 OSCrypt::SetMainThreadRunner(main_thread_runner); |
| 65 #endif | 70 #endif |
| 66 | 71 |
| 67 ChromeBrowserMainPartsPosix::PreProfileInit(); | 72 ChromeBrowserMainPartsPosix::PreProfileInit(); |
| 68 } | 73 } |
| 69 | 74 |
| 70 void ChromeBrowserMainPartsLinux::PostProfileInit() { | 75 void ChromeBrowserMainPartsLinux::PostProfileInit() { |
| 71 ChromeBrowserMainPartsPosix::PostProfileInit(); | 76 ChromeBrowserMainPartsPosix::PostProfileInit(); |
| 72 | 77 |
| 73 g_browser_process->metrics_service()->RecordBreakpadRegistration( | 78 g_browser_process->metrics_service()->RecordBreakpadRegistration( |
| 74 breakpad::IsCrashReporterEnabled()); | 79 breakpad::IsCrashReporterEnabled()); |
| (...skipping 10 matching lines...) Expand all Loading... |
| 85 } | 90 } |
| 86 | 91 |
| 87 void ChromeBrowserMainPartsLinux::PostDestroyThreads() { | 92 void ChromeBrowserMainPartsLinux::PostDestroyThreads() { |
| 88 #if !defined(OS_CHROMEOS) | 93 #if !defined(OS_CHROMEOS) |
| 89 bluez::BluezDBusManager::Shutdown(); | 94 bluez::BluezDBusManager::Shutdown(); |
| 90 bluez::DBusThreadManagerLinux::Shutdown(); | 95 bluez::DBusThreadManagerLinux::Shutdown(); |
| 91 #endif | 96 #endif |
| 92 | 97 |
| 93 ChromeBrowserMainPartsPosix::PostDestroyThreads(); | 98 ChromeBrowserMainPartsPosix::PostDestroyThreads(); |
| 94 } | 99 } |
| OLD | NEW |