| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "content/renderer/browser_plugin/browser_plugin.h" | 5 #include "content/renderer/browser_plugin/browser_plugin.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 548 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 559 if (!attached()) | 559 if (!attached()) |
| 560 return false; | 560 return false; |
| 561 | 561 |
| 562 BrowserPluginManager::Get()->Send(new BrowserPluginHostMsg_ImeCommitText( | 562 BrowserPluginManager::Get()->Send(new BrowserPluginHostMsg_ImeCommitText( |
| 563 browser_plugin_instance_id_, text.utf8(), relative_cursor_pos)); | 563 browser_plugin_instance_id_, text.utf8(), relative_cursor_pos)); |
| 564 // TODO(kochi): This assumes the IPC handling always succeeds. | 564 // TODO(kochi): This assumes the IPC handling always succeeds. |
| 565 return true; | 565 return true; |
| 566 } | 566 } |
| 567 | 567 |
| 568 bool BrowserPlugin::finishComposingText( | 568 bool BrowserPlugin::finishComposingText( |
| 569 blink::WebWidget::ConfirmCompositionBehavior selection_behavior) { | 569 blink::WebInputMethodController::ConfirmCompositionBehavior |
| 570 selection_behavior) { |
| 570 if (!attached()) | 571 if (!attached()) |
| 571 return false; | 572 return false; |
| 572 bool keep_selection = (selection_behavior == blink::WebWidget::KeepSelection); | 573 bool keep_selection = |
| 574 (selection_behavior == blink::WebInputMethodController::KeepSelection); |
| 573 BrowserPluginManager::Get()->Send( | 575 BrowserPluginManager::Get()->Send( |
| 574 new BrowserPluginHostMsg_ImeFinishComposingText(keep_selection)); | 576 new BrowserPluginHostMsg_ImeFinishComposingText(keep_selection)); |
| 575 // TODO(kochi): This assumes the IPC handling always succeeds. | 577 // TODO(kochi): This assumes the IPC handling always succeeds. |
| 576 return true; | 578 return true; |
| 577 } | 579 } |
| 578 | 580 |
| 579 void BrowserPlugin::extendSelectionAndDelete(int before, int after) { | 581 void BrowserPlugin::extendSelectionAndDelete(int before, int after) { |
| 580 if (!attached()) | 582 if (!attached()) |
| 581 return; | 583 return; |
| 582 BrowserPluginManager::Get()->Send( | 584 BrowserPluginManager::Get()->Send( |
| (...skipping 18 matching lines...) Expand all Loading... |
| 601 | 603 |
| 602 bool BrowserPlugin::HandleMouseLockedInputEvent( | 604 bool BrowserPlugin::HandleMouseLockedInputEvent( |
| 603 const blink::WebMouseEvent& event) { | 605 const blink::WebMouseEvent& event) { |
| 604 BrowserPluginManager::Get()->Send( | 606 BrowserPluginManager::Get()->Send( |
| 605 new BrowserPluginHostMsg_HandleInputEvent(browser_plugin_instance_id_, | 607 new BrowserPluginHostMsg_HandleInputEvent(browser_plugin_instance_id_, |
| 606 &event)); | 608 &event)); |
| 607 return true; | 609 return true; |
| 608 } | 610 } |
| 609 | 611 |
| 610 } // namespace content | 612 } // namespace content |
| OLD | NEW |