Index: ui/aura/window_tree_host_x11.cc |
diff --git a/ui/aura/window_tree_host_x11.cc b/ui/aura/window_tree_host_x11.cc |
index a74d0bb43bc64b57db35c68ae38957870e520b26..50330874381a4357ee762d56ea2bfa252f3164f4 100644 |
--- a/ui/aura/window_tree_host_x11.cc |
+++ b/ui/aura/window_tree_host_x11.cc |
@@ -150,38 +150,15 @@ class TouchEventCalibrate : public ui::PlatformEventObserver { |
const int resolution_x = bounds.width(); |
const int resolution_y = bounds.height(); |
pkotwicz
2015/01/23 19:34:33
My understanding is that the following is always t
Mr4D (OOO till 08-26)
2015/01/27 13:35:45
This has to be enabled by the TP driver. It was me
|
- // The "grace area" (10% in this case) is to make it easier for the user to |
- // navigate to the corner. |
- const double kGraceAreaFraction = 0.1; |
if (left_ || right_) { |
// Offset the x position to the real |
x -= left_; |
- // Check if we are in the grace area of the left side. |
- // Note: We might not want to do this when the gesture is locked? |
- if (x < 0 && x > -left_ * kGraceAreaFraction) |
- x = 0; |
- // Check if we are in the grace area of the right side. |
- // Note: We might not want to do this when the gesture is locked? |
- if (x > resolution_x - left_ && |
- x < resolution_x - left_ + right_ * kGraceAreaFraction) |
- x = resolution_x - left_; |
// Scale the screen area back to the full resolution of the screen. |
x = (x * resolution_x) / (resolution_x - (right_ + left_)); |
} |
if (top_ || bottom_) { |
// When there is a top bezel we add our border, |
y -= top_; |
- |
- // Check if we are in the grace area of the top side. |
- // Note: We might not want to do this when the gesture is locked? |
- if (y < 0 && y > -top_ * kGraceAreaFraction) |
- y = 0; |
- |
- // Check if we are in the grace area of the bottom side. |
- // Note: We might not want to do this when the gesture is locked? |
- if (y > resolution_y - top_ && |
- y < resolution_y - top_ + bottom_ * kGraceAreaFraction) |
pkotwicz
2015/01/23 19:34:33
My understanding is that this if statement is neve
Mr4D (OOO till 08-26)
2015/01/27 13:35:45
At the moment only the bottom bezel is reliable. Y
|
- y = resolution_y - top_; |
// Scale the screen area back to the full resolution of the screen. |
y = (y * resolution_y) / (resolution_y - (bottom_ + top_)); |
} |