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

Unified Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 1046783002: wip: Aura-specific implementation of unified touch selection: touch_selection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moving the responsibility for showing the menu into the client. Created 5 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.h ('k') | ui/resources/ui_resources.grd » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_widget_host_view_android.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc
index 337c9bc32dd22fb09fdeaddb1c2e61ecc5d73fd6..8239f97692a062a618464a1748e98d1d1dc55ec1 100644
--- a/content/browser/renderer_host/render_widget_host_view_android.cc
+++ b/content/browser/renderer_host/render_widget_host_view_android.cc
@@ -87,7 +87,6 @@
#include "ui/gfx/geometry/dip_util.h"
#include "ui/gfx/geometry/size_conversions.h"
#include "ui/gfx/screen.h"
-#include "ui/touch_selection/touch_selection_controller.h"
namespace content {
@@ -277,19 +276,17 @@ ui::LatencyInfo CreateLatencyInfo(const blink::WebInputEvent& event) {
return latency_info;
}
-scoped_ptr<ui::TouchSelectionController> CreateSelectionController(
- ui::TouchSelectionControllerClient* client,
+scoped_ptr<ui::TouchSelectionControllerAndroid> CreateSelectionController(
+ ui::TouchSelectionControllerAndroidClient* client,
ContentViewCore* content_view_core) {
DCHECK(client);
DCHECK(content_view_core);
int tap_timeout_ms = gfx::ViewConfiguration::GetTapTimeoutInMs();
int touch_slop_pixels = gfx::ViewConfiguration::GetTouchSlopInPixels();
- bool show_on_tap_for_empty_editable = false;
- return make_scoped_ptr(new ui::TouchSelectionController(
+ return make_scoped_ptr(new ui::TouchSelectionControllerAndroid(
client,
base::TimeDelta::FromMilliseconds(tap_timeout_ms),
- touch_slop_pixels / content_view_core->GetDpiScale(),
- show_on_tap_for_empty_editable));
+ touch_slop_pixels / content_view_core->GetDpiScale()));
}
scoped_ptr<OverscrollControllerAndroid> CreateOverscrollController(
@@ -1421,7 +1418,7 @@ void RenderWidgetHostViewAndroid::OnFrameMetadataUpdated(
overscroll_controller_->OnFrameMetadataUpdated(frame_metadata);
if (selection_controller_) {
- selection_controller_->OnSelectionBoundsChanged(
+ selection_controller_->OnSelectionBoundsUpdated(
ConvertSelectionBound(frame_metadata.selection_start),
ConvertSelectionBound(frame_metadata.selection_end));
}
@@ -1811,7 +1808,7 @@ void RenderWidgetHostViewAndroid::OnShowingPastePopup(
selection_controller_->HideAndDisallowShowingAutomatically();
selection_controller_->OnSelectionEditable(true);
selection_controller_->OnSelectionEmpty(true);
- selection_controller_->OnSelectionBoundsChanged(insertion_bound,
+ selection_controller_->OnSelectionBoundsUpdated(insertion_bound,
insertion_bound);
selection_controller_->AllowShowingFromCurrentSelection();
}
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.h ('k') | ui/resources/ui_resources.grd » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698