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 "ui/base/ime/input_method_ibus.h" | 5 #include "ui/base/ime/input_method_ibus.h" |
6 | 6 |
7 #include <X11/X.h> | 7 #include <X11/X.h> |
8 #include <X11/Xlib.h> | 8 #include <X11/Xlib.h> |
9 #include <X11/Xutil.h> | 9 #include <X11/Xutil.h> |
10 #undef FocusIn | 10 #undef FocusIn |
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
330 | 330 |
331 base::i18n::TextDirection InputMethodIBus::GetInputTextDirection() { | 331 base::i18n::TextDirection InputMethodIBus::GetInputTextDirection() { |
332 // Not supported. | 332 // Not supported. |
333 return base::i18n::UNKNOWN_DIRECTION; | 333 return base::i18n::UNKNOWN_DIRECTION; |
334 } | 334 } |
335 | 335 |
336 bool InputMethodIBus::IsActive() { | 336 bool InputMethodIBus::IsActive() { |
337 return true; | 337 return true; |
338 } | 338 } |
339 | 339 |
| 340 bool InputMethodIBus::IsCandidatePopupOpen() const { |
| 341 // TODO(yukishiino): Implement this method. |
| 342 return false; |
| 343 } |
| 344 |
340 void InputMethodIBus::OnWillChangeFocusedClient(TextInputClient* focused_before, | 345 void InputMethodIBus::OnWillChangeFocusedClient(TextInputClient* focused_before, |
341 TextInputClient* focused) { | 346 TextInputClient* focused) { |
342 ConfirmCompositionText(); | 347 ConfirmCompositionText(); |
343 } | 348 } |
344 | 349 |
345 void InputMethodIBus::OnDidChangeFocusedClient(TextInputClient* focused_before, | 350 void InputMethodIBus::OnDidChangeFocusedClient(TextInputClient* focused_before, |
346 TextInputClient* focused) { | 351 TextInputClient* focused) { |
347 // Force to update the input type since client's TextInputStateChanged() | 352 // Force to update the input type since client's TextInputStateChanged() |
348 // function might not be called if text input types before the client loses | 353 // function might not be called if text input types before the client loses |
349 // focus and after it acquires focus again are the same. | 354 // focus and after it acquires focus again are the same. |
(...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
964 } | 969 } |
965 | 970 |
966 // Use a black thin underline by default. | 971 // Use a black thin underline by default. |
967 if (out_composition->underlines.empty()) { | 972 if (out_composition->underlines.empty()) { |
968 out_composition->underlines.push_back(CompositionUnderline( | 973 out_composition->underlines.push_back(CompositionUnderline( |
969 0, length, SK_ColorBLACK, false /* thick */)); | 974 0, length, SK_ColorBLACK, false /* thick */)); |
970 } | 975 } |
971 } | 976 } |
972 | 977 |
973 } // namespace ui | 978 } // namespace ui |
OLD | NEW |