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

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 2864833002: Tapping handle shouldn't select misspelled word (Closed)
Patch Set: Mac test Created 3 years, 7 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/browser/renderer_host/render_widget_host_view_android.h" 5 #include "content/browser/renderer_host/render_widget_host_view_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 #include "gpu/config/gpu_driver_bug_workaround_type.h" 76 #include "gpu/config/gpu_driver_bug_workaround_type.h"
77 #include "ipc/ipc_message_macros.h" 77 #include "ipc/ipc_message_macros.h"
78 #include "ipc/ipc_message_start.h" 78 #include "ipc/ipc_message_start.h"
79 #include "skia/ext/image_operations.h" 79 #include "skia/ext/image_operations.h"
80 #include "third_party/khronos/GLES2/gl2.h" 80 #include "third_party/khronos/GLES2/gl2.h"
81 #include "third_party/khronos/GLES2/gl2ext.h" 81 #include "third_party/khronos/GLES2/gl2ext.h"
82 #include "third_party/skia/include/core/SkCanvas.h" 82 #include "third_party/skia/include/core/SkCanvas.h"
83 #include "ui/android/window_android.h" 83 #include "ui/android/window_android.h"
84 #include "ui/android/window_android_compositor.h" 84 #include "ui/android/window_android_compositor.h"
85 #include "ui/base/layout.h" 85 #include "ui/base/layout.h"
86 #include "ui/base/ui_base_types.h"
86 #include "ui/events/android/motion_event_android.h" 87 #include "ui/events/android/motion_event_android.h"
87 #include "ui/events/base_event_utils.h" 88 #include "ui/events/base_event_utils.h"
88 #include "ui/events/blink/blink_event_util.h" 89 #include "ui/events/blink/blink_event_util.h"
89 #include "ui/events/blink/did_overscroll_params.h" 90 #include "ui/events/blink/did_overscroll_params.h"
90 #include "ui/events/blink/web_input_event_traits.h" 91 #include "ui/events/blink/web_input_event_traits.h"
91 #include "ui/events/gesture_detection/gesture_provider_config_helper.h" 92 #include "ui/events/gesture_detection/gesture_provider_config_helper.h"
92 #include "ui/gfx/android/java_bitmap.h" 93 #include "ui/gfx/android/java_bitmap.h"
93 #include "ui/gfx/android/view_configuration.h" 94 #include "ui/gfx/android/view_configuration.h"
94 #include "ui/gfx/geometry/dip_util.h" 95 #include "ui/gfx/geometry/dip_util.h"
95 #include "ui/gfx/geometry/size_conversions.h" 96 #include "ui/gfx/geometry/size_conversions.h"
(...skipping 1754 matching lines...) Expand 10 before | Expand all | Expand 10 after
1850 } 1851 }
1851 1852
1852 void RenderWidgetHostViewAndroid::MoveCaret(const gfx::Point& point) { 1853 void RenderWidgetHostViewAndroid::MoveCaret(const gfx::Point& point) {
1853 if (host_) 1854 if (host_)
1854 host_->MoveCaret(point); 1855 host_->MoveCaret(point);
1855 } 1856 }
1856 1857
1857 void RenderWidgetHostViewAndroid::ShowContextMenuAtPoint( 1858 void RenderWidgetHostViewAndroid::ShowContextMenuAtPoint(
1858 const gfx::Point& point) { 1859 const gfx::Point& point) {
1859 if (host_) 1860 if (host_)
1860 host_->ShowContextMenuAtPoint(point); 1861 host_->ShowContextMenuAtPoint(point, ui::MENU_SOURCE_TOUCH_HANDLE);
bokan 2017/05/23 14:06:02 Could we plumb this value up so that we specify TO
amaralp 2017/05/23 19:37:53 I changed the name of the functions from ShowConte
bokan 2017/05/24 18:28:22 Acknowledged.
1861 } 1862 }
1862 1863
1863 void RenderWidgetHostViewAndroid::DismissTextHandles() { 1864 void RenderWidgetHostViewAndroid::DismissTextHandles() {
1864 if (touch_selection_controller_) 1865 if (touch_selection_controller_)
1865 touch_selection_controller_->HideAndDisallowShowingAutomatically(); 1866 touch_selection_controller_->HideAndDisallowShowingAutomatically();
1866 } 1867 }
1867 1868
1868 void RenderWidgetHostViewAndroid::SetTextHandlesTemporarilyHidden(bool hidden) { 1869 void RenderWidgetHostViewAndroid::SetTextHandlesTemporarilyHidden(bool hidden) {
1869 if (touch_selection_controller_) 1870 if (touch_selection_controller_)
1870 touch_selection_controller_->SetTemporarilyHidden(hidden); 1871 touch_selection_controller_->SetTemporarilyHidden(hidden);
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
2230 2231
2231 ui::WindowAndroidCompositor* compositor = window_android->GetCompositor(); 2232 ui::WindowAndroidCompositor* compositor = window_android->GetCompositor();
2232 if (!compositor) 2233 if (!compositor)
2233 return; 2234 return;
2234 2235
2235 overscroll_controller_ = base::MakeUnique<OverscrollControllerAndroid>( 2236 overscroll_controller_ = base::MakeUnique<OverscrollControllerAndroid>(
2236 overscroll_refresh_handler, compositor, view_.GetDipScale()); 2237 overscroll_refresh_handler, compositor, view_.GetDipScale());
2237 } 2238 }
2238 2239
2239 } // namespace content 2240 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698