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

Unified Diff: content/browser/renderer_host/input/ui_touch_selection_helper.cc

Issue 2030033003: Replace cc::ViewportSelectionBound with gfx::SelectionBound (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Further cleanup Created 4 years, 6 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
Index: content/browser/renderer_host/input/ui_touch_selection_helper.cc
diff --git a/content/browser/renderer_host/input/ui_touch_selection_helper.cc b/content/browser/renderer_host/input/ui_touch_selection_helper.cc
deleted file mode 100644
index 8c030c9f70af811d22d0c2b18e554817d72567b8..0000000000000000000000000000000000000000
--- a/content/browser/renderer_host/input/ui_touch_selection_helper.cc
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/browser/renderer_host/input/ui_touch_selection_helper.h"
-
-#include "base/logging.h"
-#include "cc/output/viewport_selection_bound.h"
-
-namespace content {
-
-namespace {
-
-gfx::SelectionBound::Type ConvertSelectionBoundType(
- cc::SelectionBoundType type) {
- switch (type) {
- case cc::SELECTION_BOUND_LEFT:
- return gfx::SelectionBound::LEFT;
- case cc::SELECTION_BOUND_RIGHT:
- return gfx::SelectionBound::RIGHT;
- case cc::SELECTION_BOUND_CENTER:
- return gfx::SelectionBound::CENTER;
- case cc::SELECTION_BOUND_EMPTY:
- return gfx::SelectionBound::EMPTY;
- }
- NOTREACHED() << "Unknown selection bound type";
- return gfx::SelectionBound::EMPTY;
-}
-
-} // namespace
-
-gfx::SelectionBound ConvertSelectionBound(
- const cc::ViewportSelectionBound& bound) {
- gfx::SelectionBound ui_bound;
- ui_bound.set_type(ConvertSelectionBoundType(bound.type));
- ui_bound.set_visible(bound.visible);
- if (ui_bound.type() != gfx::SelectionBound::EMPTY)
- ui_bound.SetEdge(bound.edge_top, bound.edge_bottom);
- return ui_bound;
-}
-
-} // namespace content

Powered by Google App Engine
This is Rietveld 408576698