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

Unified Diff: ui/touch_selection/touch_handle.cc

Issue 481683003: Support for Adaptive Handle Orientation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Initial patchset Created 5 years, 9 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: ui/touch_selection/touch_handle.cc
diff --git a/ui/touch_selection/touch_handle.cc b/ui/touch_selection/touch_handle.cc
index 0f28c3fedf8d69068acba4969db54e13cbd60bda..960e961e064e60b8c506e2c5a757b993707d10f0 100644
--- a/ui/touch_selection/touch_handle.cc
+++ b/ui/touch_selection/touch_handle.cc
@@ -54,6 +54,20 @@ static std::ostream& operator<<(std::ostream& os,
return os << "RIGHT";
case TouchHandleOrientation::CENTER:
return os << "CENTER";
+ case TouchHandleOrientation::LEFT_INVERTED:
+ return os << "LEFT_INVERTED";
+ case TouchHandleOrientation::RIGHT_INVERTED:
+ return os << "RIGHT_INVERTED";
+ case TouchHandleOrientation::LEFT_FLIPPED:
+ return os << "LEFT_FLIPPED";
+ case TouchHandleOrientation::RIGHT_FLIPPED:
+ return os << "RIGHT_FLIPPED";
+ case TouchHandleOrientation::LEFT_FLIPPED_INVERTED:
+ return os << "LEFT_FLIPPED_INVERTED";
+ case TouchHandleOrientation::RIGHT_FLIPPED_INVERTED:
+ return os << "RIGHT_FLIPPED_INVERTED";
+ case TouchHandleOrientation::CENTER_INVERTED:
+ return os << "CENTER_INVERTED";
case TouchHandleOrientation::UNDEFINED:
return os << "UNDEFINED";
default:
@@ -294,4 +308,8 @@ void TouchHandle::SetAlpha(float alpha) {
drawable_->SetAlpha(alpha);
}
+gfx::RectF TouchHandle::GetHandleBounds() {
+ return drawable_->GetVisibleBounds();
+}
+
} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698