Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(111)

Side by Side Diff: content/renderer/render_widget.cc

Issue 59553003: Do not show IME on every touchend event when input field has focus (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tweaking unit test further Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "content/renderer/render_widget.h" 5 #include "content/renderer/render_widget.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/debug/trace_event.h" 9 #include "base/debug/trace_event.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 1172 matching lines...) Expand 10 before | Expand all | Expand 10 after
1183 Send(pending_input_event_ack_.release()); 1183 Send(pending_input_event_ack_.release());
1184 } 1184 }
1185 pending_input_event_ack_ = response.Pass(); 1185 pending_input_event_ack_ = response.Pass();
1186 if (compositor_) 1186 if (compositor_)
1187 compositor_->NotifyInputThrottledUntilCommit(); 1187 compositor_->NotifyInputThrottledUntilCommit();
1188 } else { 1188 } else {
1189 Send(response.release()); 1189 Send(response.release());
1190 } 1190 }
1191 } 1191 }
1192 1192
1193 #if defined(OS_ANDROID)
1194 // Allow the IME to be shown when the focus changes as a consequence
1195 // of a processed touch end event.
1196 if (input_event->type == WebInputEvent::TouchEnd && processed)
1197 UpdateTextInputState(true, true);
1198 #endif
1199
1200 handling_input_event_ = false; 1193 handling_input_event_ = false;
1201 1194
1202 if (!prevent_default) { 1195 if (!prevent_default) {
1203 if (WebInputEvent::isKeyboardEventType(input_event->type)) 1196 if (WebInputEvent::isKeyboardEventType(input_event->type))
1204 DidHandleKeyEvent(); 1197 DidHandleKeyEvent();
1205 if (WebInputEvent::isMouseEventType(input_event->type)) 1198 if (WebInputEvent::isMouseEventType(input_event->type))
1206 DidHandleMouseEvent(*(static_cast<const WebMouseEvent*>(input_event))); 1199 DidHandleMouseEvent(*(static_cast<const WebMouseEvent*>(input_event)));
1207 if (WebInputEvent::isTouchEventType(input_event->type)) 1200 if (WebInputEvent::isTouchEventType(input_event->type))
1208 DidHandleTouchEvent(*(static_cast<const WebTouchEvent*>(input_event))); 1201 DidHandleTouchEvent(*(static_cast<const WebTouchEvent*>(input_event)));
1209 } 1202 }
(...skipping 1657 matching lines...) Expand 10 before | Expand all | Expand 10 after
2867 surface_id(), 2860 surface_id(),
2868 GetURLForGraphicsContext3D(), 2861 GetURLForGraphicsContext3D(),
2869 gpu_channel_host.get(), 2862 gpu_channel_host.get(),
2870 attributes, 2863 attributes,
2871 false /* bind generates resources */, 2864 false /* bind generates resources */,
2872 limits)); 2865 limits));
2873 return context.Pass(); 2866 return context.Pass();
2874 } 2867 }
2875 2868
2876 } // namespace content 2869 } // namespace content
OLDNEW
« content/renderer/render_view_impl.cc ('K') | « content/renderer/render_view_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698