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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 | 43 |
44 ChromeBrowserMainPartsPosix::ToolkitInitialized(); | 44 ChromeBrowserMainPartsPosix::ToolkitInitialized(); |
45 } | 45 } |
46 | 46 |
47 void ChromeBrowserMainPartsLinux::PreProfileInit() { | 47 void ChromeBrowserMainPartsLinux::PreProfileInit() { |
48 #if !defined(OS_CHROMEOS) | 48 #if !defined(OS_CHROMEOS) |
49 // Needs to be called after we have chrome::DIR_USER_DATA and | 49 // Needs to be called after we have chrome::DIR_USER_DATA and |
50 // g_browser_process. This happens in PreCreateThreads. | 50 // g_browser_process. This happens in PreCreateThreads. |
51 // base::GetLinuxDistro() will initialize its value if needed. | 51 // base::GetLinuxDistro() will initialize its value if needed. |
52 base::PostTaskWithTraits( | 52 base::PostTaskWithTraits( |
53 FROM_HERE, | 53 FROM_HERE, {base::MayBlock(), base::TaskPriority::BACKGROUND}, |
54 base::TaskTraits().MayBlock().WithPriority( | |
55 base::TaskPriority::BACKGROUND), | |
56 base::BindOnce(base::IgnoreResult(&base::GetLinuxDistro))); | 54 base::BindOnce(base::IgnoreResult(&base::GetLinuxDistro))); |
57 #endif | 55 #endif |
58 | 56 |
59 media::AudioManager::SetGlobalAppName( | 57 media::AudioManager::SetGlobalAppName( |
60 l10n_util::GetStringUTF8(IDS_SHORT_PRODUCT_NAME)); | 58 l10n_util::GetStringUTF8(IDS_SHORT_PRODUCT_NAME)); |
61 | 59 |
62 #if !defined(OS_CHROMEOS) | 60 #if !defined(OS_CHROMEOS) |
63 // Forward to os_crypt the flag to use a specific password store. | 61 // Forward to os_crypt the flag to use a specific password store. |
64 OSCrypt::SetStore( | 62 OSCrypt::SetStore( |
65 parsed_command_line().GetSwitchValueASCII(switches::kPasswordStore)); | 63 parsed_command_line().GetSwitchValueASCII(switches::kPasswordStore)); |
(...skipping 27 matching lines...) Expand all Loading... |
93 } | 91 } |
94 | 92 |
95 void ChromeBrowserMainPartsLinux::PostDestroyThreads() { | 93 void ChromeBrowserMainPartsLinux::PostDestroyThreads() { |
96 #if !defined(OS_CHROMEOS) | 94 #if !defined(OS_CHROMEOS) |
97 bluez::BluezDBusManager::Shutdown(); | 95 bluez::BluezDBusManager::Shutdown(); |
98 bluez::DBusThreadManagerLinux::Shutdown(); | 96 bluez::DBusThreadManagerLinux::Shutdown(); |
99 #endif | 97 #endif |
100 | 98 |
101 ChromeBrowserMainPartsPosix::PostDestroyThreads(); | 99 ChromeBrowserMainPartsPosix::PostDestroyThreads(); |
102 } | 100 } |
OLD | NEW |