Class GravitySensor
- Namespace
- CSharpToJavaScript.APIs.JS
- Assembly
- CSharpToJavaScript.dll
The GravitySensor interface of the Sensor APIs provides on each reading the gravity applied to the device along all three axes.
[Value("GravitySensor")]
public class GravitySensor : Accelerometer
- Inheritance
-
GravitySensor
- Inherited Members
Remarks
To use this sensor, the user must grant permission to the 'accelerometer' device sensor through the Permissions API. In addition, this feature may be blocked by a Permissions Policy set on your server.
Constructors
GravitySensor()
public GravitySensor()
GravitySensor(AccelerometerSensorOptions)
The GravitySensor()
constructor creates a new GravitySensor object which
provides on each reading the gravity applied to the device along all three axes.
public GravitySensor(AccelerometerSensorOptions options = null)
Parameters
optionsAccelerometerSensorOptions
Remarks
-'sensor.Reading' event