Chromium Code Reviews| Index: content/renderer/render_view_impl.cc |
| diff --git a/content/renderer/render_view_impl.cc b/content/renderer/render_view_impl.cc |
| index 224cb16f4c42e163a00131e049cb9bfa46244295..9a4df03f830c0c9374854c4dec6b69e6ca897ac0 100644 |
| --- a/content/renderer/render_view_impl.cc |
| +++ b/content/renderer/render_view_impl.cc |
| @@ -204,6 +204,7 @@ |
| #include "content/renderer/android/email_detector.h" |
| #include "content/renderer/android/phone_number_detector.h" |
| #include "content/renderer/media/stream_texture_factory_impl_android.h" |
| +#include "third_party/WebKit/Source/WebKit/chromium/public/android/WebInputEventFactory.h" |
| #include "third_party/WebKit/Source/WebKit/chromium/public/WebHitTestResult.h" |
| #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebFloatPoint.h" |
| #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebFloatRect.h" |
| @@ -250,12 +251,14 @@ using WebKit::WebFindOptions; |
| using WebKit::WebFormControlElement; |
| using WebKit::WebFormElement; |
| using WebKit::WebFrame; |
| +using WebKit::WebGestureEvent; |
| using WebKit::WebGraphicsContext3D; |
| using WebKit::WebHistoryItem; |
| using WebKit::WebHTTPBody; |
| using WebKit::WebIconURL; |
| using WebKit::WebImage; |
| using WebKit::WebInputElement; |
| +using WebKit::WebInputEvent; |
| using WebKit::WebIntentRequest; |
| using WebKit::WebIntentServiceInfo; |
| using WebKit::WebMediaPlayer; |
| @@ -335,6 +338,7 @@ using WebKit::WebContentDetectionResult; |
| using WebKit::WebFloatPoint; |
| using WebKit::WebFloatRect; |
| using WebKit::WebHitTestResult; |
| +using WebKit::WebInputEventFactory; |
| #endif |
| //----------------------------------------------------------------------------- |
| @@ -2067,6 +2071,16 @@ bool RenderViewImpl::handleCurrentKeyboardEvent() { |
| return did_execute_command; |
| } |
| +void RenderViewImpl::didHandleGestureEvent(const WebGestureEvent& event, |
| + bool eventSwallowed) { |
|
jam
2012/09/20 18:01:22
nit: event_swallowed per style guide (also in head
olilan
2012/09/21 11:23:56
Done.
|
| +#if defined(OS_ANDROID) |
| + if (event.type == WebInputEvent::GestureTap |
| + || event.type == WebInputEvent::GestureLongPress) { |
|
jam
2012/09/20 18:01:22
nit: || should be on previous line per style guide
olilan
2012/09/21 11:23:56
Done.
|
| + UpdateTextInputState(SHOW_IME_IF_NEEDED); |
| + } |
| +#endif |
| +} |
| + |
| WebKit::WebColorChooser* RenderViewImpl::createColorChooser( |
| WebKit::WebColorChooserClient* client, |
| const WebKit::WebColor& initial_color) { |
| @@ -5612,12 +5626,12 @@ void RenderViewImpl::OnSetFocus(bool enable) { |
| } |
| void RenderViewImpl::PpapiPluginFocusChanged() { |
| - UpdateTextInputState(); |
| + UpdateTextInputState(DO_NOT_SHOW_IME); |
| UpdateSelectionBounds(); |
| } |
| void RenderViewImpl::PpapiPluginTextInputTypeChanged() { |
| - UpdateTextInputState(); |
| + UpdateTextInputState(DO_NOT_SHOW_IME); |
| if (renderer_accessibility_) |
| renderer_accessibility_->FocusedNodeChanged(WebNode()); |
| } |