| 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/views/ime/input_method_bridge.h" | 5 #include "ui/views/ime/input_method_bridge.h" |
| 6 | 6 |
| 7 #include "ui/base/ime/input_method.h" | 7 #include "ui/base/ime/input_method.h" |
| 8 #include "ui/base/ime/input_method_observer.h" | 8 #include "ui/base/ime/input_method_observer.h" |
| 9 #include "ui/events/event.h" | 9 #include "ui/events/event.h" |
| 10 #include "ui/gfx/geometry/rect.h" | 10 #include "ui/gfx/geometry/rect.h" |
| (...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 if (client) | 304 if (client) |
| 305 client->ExtendSelectionAndDelete(before, after); | 305 client->ExtendSelectionAndDelete(before, after); |
| 306 } | 306 } |
| 307 | 307 |
| 308 void InputMethodBridge::EnsureCaretInRect(const gfx::Rect& rect) { | 308 void InputMethodBridge::EnsureCaretInRect(const gfx::Rect& rect) { |
| 309 TextInputClient* client = GetTextInputClient(); | 309 TextInputClient* client = GetTextInputClient(); |
| 310 if (client) | 310 if (client) |
| 311 client->EnsureCaretInRect(rect); | 311 client->EnsureCaretInRect(rect); |
| 312 } | 312 } |
| 313 | 313 |
| 314 void InputMethodBridge::OnCandidateWindowShown() { | |
| 315 } | |
| 316 | |
| 317 void InputMethodBridge::OnCandidateWindowUpdated() { | |
| 318 } | |
| 319 | |
| 320 void InputMethodBridge::OnCandidateWindowHidden() { | |
| 321 } | |
| 322 | |
| 323 bool InputMethodBridge::IsEditCommandEnabled(int command_id) { | 314 bool InputMethodBridge::IsEditCommandEnabled(int command_id) { |
| 324 TextInputClient* client = GetTextInputClient(); | 315 TextInputClient* client = GetTextInputClient(); |
| 325 return client ? client->IsEditCommandEnabled(command_id) : false; | 316 return client ? client->IsEditCommandEnabled(command_id) : false; |
| 326 } | 317 } |
| 327 | 318 |
| 328 void InputMethodBridge::SetEditCommandForNextKeyEvent(int command_id) { | 319 void InputMethodBridge::SetEditCommandForNextKeyEvent(int command_id) { |
| 329 TextInputClient* client = GetTextInputClient(); | 320 TextInputClient* client = GetTextInputClient(); |
| 330 if (client) | 321 if (client) |
| 331 client->SetEditCommandForNextKeyEvent(command_id); | 322 client->SetEditCommandForNextKeyEvent(command_id); |
| 332 } | 323 } |
| (...skipping 11 matching lines...) Expand all Loading... |
| 344 OnTextInputTypeChanged(focused); | 335 OnTextInputTypeChanged(focused); |
| 345 OnCaretBoundsChanged(focused); | 336 OnCaretBoundsChanged(focused); |
| 346 } | 337 } |
| 347 | 338 |
| 348 ui::InputMethod* InputMethodBridge::GetHostInputMethod() const { | 339 ui::InputMethod* InputMethodBridge::GetHostInputMethod() const { |
| 349 return host_; | 340 return host_; |
| 350 } | 341 } |
| 351 | 342 |
| 352 | 343 |
| 353 } // namespace views | 344 } // namespace views |
| OLD | NEW |