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

Unified Diff: extensions/common/api/system_display.idl

Issue 2538623002: Adds touch calibration methods to system_display.idl API (Closed)
Patch Set: Adds touch calibration methods to system.idl API Created 4 years, 1 month 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: extensions/common/api/system_display.idl
diff --git a/extensions/common/api/system_display.idl b/extensions/common/api/system_display.idl
index b0600f4972c20a97a8da071fbdb40de89a9561b8..bb135e040e7bc635ff6f634445b74e83879d5c94 100644
--- a/extensions/common/api/system_display.idl
+++ b/extensions/common/api/system_display.idl
@@ -33,6 +33,36 @@ namespace system.display {
long bottom;
};
+ dictionary Point {
+ // The x-coordinate of the point.
+ long x;
+
+ // The y-coordinate of the point.
+ long y;
+ };
+
+ dictionary TouchCalibrationPair {
+ // The coordinates of the display point.
+ Point displayPoint;
+
+ // The coordinates of the touch point corresponding to the display point.
+ Point touchPoint;
+ };
+
+ dictionary TouchCalibrationPairQuad {
+ // First pair of touch and display point required for touch calibration.
+ TouchCalibrationPair pair1;
+
+ // Second pair of touch and display point required for touch calibration.
+ TouchCalibrationPair pair2;
+
+ // Third pair of touch and display point required for touch calibration.
+ TouchCalibrationPair pair3;
+
+ // Fourth pair of touch and display point required for touch calibration.
+ TouchCalibrationPair pair4;
+ };
+
dictionary DisplayMode {
// The display mode width in device independent (user visible) pixels.
long width;
@@ -242,6 +272,28 @@ namespace system.display {
// and hiding the overlay.
// |id|: The display's unique identifier.
static void overscanCalibrationComplete(DOMString id);
+
+ // Starts touch calibration for a display. This will show an overlay on the
+ // screen and initialize the UX for touch calibration. If touch calibration
+ // for display |id| is in progress this will do nothing.
stevenjb 2016/11/29 18:53:29 We should throw an error of calibration is in prog
malaykeshav 2016/11/30 00:53:16 Done
+ // |id|: The display's unique identifier.
+ static void touchCalibrationStart(DOMString id);
+
+ // Sets the touch calibration pairs for a display. These |pairs| would be
+ // used to calibrate the touch screen for display |id|. If touch calibration
+ // for display |id| is in progress this will do nothing.
+ // |id|: The display's unique identifier.
+ // |pairs|: The pairs of point used to calibrate the display.
+ // |bounds|: Bounds of the display when the touch calibration was performed.
+ // |bounds.left| and |bounds.top| values are no-op.
stevenjb 2016/11/29 18:53:29 s/no-op/ignored/ ?
malaykeshav 2016/11/30 00:53:16 Done
+ static void touchCalibrationSet(DOMString id,
+ TouchCalibrationPairQuad pairs,
+ Bounds bounds);
+
+ // Resets the touch calibration for the display and removes the saved
+ // calibration data.
+ // |id|: The display's unique identifier.
+ static void touchCalibrationReset(DOMString id);
};
interface Events {

Powered by Google App Engine
This is Rietveld 408576698