OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/chromeos/base/locale_util.h" | 5 #include "chrome/browser/chromeos/base/locale_util.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/task_scheduler/post_task.h" | 10 #include "base/task_scheduler/post_task.h" |
11 #include "chrome/browser/browser_process.h" | 11 #include "chrome/browser/browser_process.h" |
12 #include "chrome/browser/chromeos/input_method/input_method_util.h" | |
13 #include "chrome/browser/chromeos/login/session/user_session_manager.h" | 12 #include "chrome/browser/chromeos/login/session/user_session_manager.h" |
14 #include "chrome/browser/profiles/profile.h" | 13 #include "chrome/browser/profiles/profile.h" |
15 #include "content/public/browser/browser_thread.h" | 14 #include "content/public/browser/browser_thread.h" |
16 #include "ui/base/ime/chromeos/input_method_manager.h" | 15 #include "ui/base/ime/chromeos/input_method_manager.h" |
| 16 #include "ui/base/ime/chromeos/input_method_util.h" |
17 #include "ui/base/resource/resource_bundle.h" | 17 #include "ui/base/resource/resource_bundle.h" |
18 #include "ui/gfx/platform_font_linux.h" | 18 #include "ui/gfx/platform_font_linux.h" |
19 | 19 |
20 namespace chromeos { | 20 namespace chromeos { |
21 | 21 |
22 namespace { | 22 namespace { |
23 | 23 |
24 struct SwitchLanguageData { | 24 struct SwitchLanguageData { |
25 SwitchLanguageData(const std::string& locale, | 25 SwitchLanguageData(const std::string& locale, |
26 const bool enable_locale_keyboard_layouts, | 26 const bool enable_locale_keyboard_layouts, |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 login_layouts_only, callback, profile)); | 123 login_layouts_only, callback, profile)); |
124 base::Closure reloader( | 124 base::Closure reloader( |
125 base::Bind(&SwitchLanguageDoReloadLocale, base::Unretained(data.get()))); | 125 base::Bind(&SwitchLanguageDoReloadLocale, base::Unretained(data.get()))); |
126 base::PostTaskWithTraitsAndReply( | 126 base::PostTaskWithTraitsAndReply( |
127 FROM_HERE, {base::MayBlock(), base::TaskPriority::BACKGROUND}, reloader, | 127 FROM_HERE, {base::MayBlock(), base::TaskPriority::BACKGROUND}, reloader, |
128 base::Bind(&FinishSwitchLanguage, base::Passed(std::move(data)))); | 128 base::Bind(&FinishSwitchLanguage, base::Passed(std::move(data)))); |
129 } | 129 } |
130 | 130 |
131 } // namespace locale_util | 131 } // namespace locale_util |
132 } // namespace chromeos | 132 } // namespace chromeos |
OLD | NEW |