| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/input_method/input_method_manager.h" | 5 #include "chrome/browser/chromeos/input_method/input_method_manager.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include <glib.h> | 9 #include <glib.h> |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 #include "content/public/browser/notification_types.h" | 30 #include "content/public/browser/notification_types.h" |
| 31 #include "googleurl/src/gurl.h" | 31 #include "googleurl/src/gurl.h" |
| 32 | 32 |
| 33 #if !defined(TOUCH_UI) | 33 #if !defined(TOUCH_UI) |
| 34 #include "chrome/browser/chromeos/input_method/candidate_window.h" | 34 #include "chrome/browser/chromeos/input_method/candidate_window.h" |
| 35 #endif | 35 #endif |
| 36 | 36 |
| 37 #include <X11/X.h> // ShiftMask, ControlMask, etc. | 37 #include <X11/X.h> // ShiftMask, ControlMask, etc. |
| 38 #include <X11/Xutil.h> // for XK_* macros. | 38 #include <X11/Xutil.h> // for XK_* macros. |
| 39 | 39 |
| 40 using content::BrowserThread; |
| 41 |
| 40 namespace { | 42 namespace { |
| 41 | 43 |
| 42 const char kIBusDaemonPath[] = "/usr/bin/ibus-daemon"; | 44 const char kIBusDaemonPath[] = "/usr/bin/ibus-daemon"; |
| 43 const size_t kMaxInputMethodsPerHotkey = 2; | 45 const size_t kMaxInputMethodsPerHotkey = 2; |
| 44 | 46 |
| 45 // For hotkey handling. | 47 // For hotkey handling. |
| 46 enum HotkeyEvent { | 48 enum HotkeyEvent { |
| 47 // Global hotkeys. | 49 // Global hotkeys. |
| 48 kPreviousInputMethod = 0, | 50 kPreviousInputMethod = 0, |
| 49 kNextInputMethod, | 51 kNextInputMethod, |
| (...skipping 1333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1383 return InputMethodManagerImpl::GetInstance(); | 1385 return InputMethodManagerImpl::GetInstance(); |
| 1384 } | 1386 } |
| 1385 | 1387 |
| 1386 } // namespace input_method | 1388 } // namespace input_method |
| 1387 } // namespace chromeos | 1389 } // namespace chromeos |
| 1388 | 1390 |
| 1389 // Allows InvokeLater without adding refcounting. This class is a Singleton and | 1391 // Allows InvokeLater without adding refcounting. This class is a Singleton and |
| 1390 // won't be deleted until it's last InvokeLater is run. | 1392 // won't be deleted until it's last InvokeLater is run. |
| 1391 DISABLE_RUNNABLE_METHOD_REFCOUNT( | 1393 DISABLE_RUNNABLE_METHOD_REFCOUNT( |
| 1392 chromeos::input_method::InputMethodManagerImpl); | 1394 chromeos::input_method::InputMethodManagerImpl); |
| OLD | NEW |