Home
last modified time | relevance | path

Searched refs:mSensorManager (Results 1 – 6 of 6) sorted by relevance

/packages/apps/Camera2/src/com/android/camera/hardware/
DHeadingSensor.java39 private final SensorManager mSensorManager; field in HeadingSensor
59 mSensorManager = sensorManager; in HeadingSensor()
60 mAccelerometerSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER); in HeadingSensor()
61 mMagneticSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD); in HeadingSensor()
81 mSensorManager.registerListener(this, mAccelerometerSensor, in activate()
85 mSensorManager.registerListener(this, mMagneticSensor, in activate()
96 mSensorManager.unregisterListener(this, mAccelerometerSensor); in deactivate()
99 mSensorManager.unregisterListener(this, mMagneticSensor); in deactivate()
/packages/services/Telecomm/tests/src/com/android/server/telecom/tests/
DSystemStateHelperTest.java79 @Mock SensorManager mSensorManager; field in SystemStateHelperTest
90 doReturn(mSensorManager).when(mContext).getSystemService(SensorManager.class); in setUp()
94 when(mSensorManager.getDefaultSensor(Sensor.TYPE_GRAVITY)).thenReturn(mGravitySensor); in setUp()
95 when(mSensorManager.getDefaultSensor(Sensor.TYPE_PROXIMITY)).thenReturn(mProxSensor); in setUp()
294 }).when(mSensorManager) in testDeviceOnEarCorrectlyDetected()
298 verify(mSensorManager).unregisterListener(any(SensorEventListener.class)); in testDeviceOnEarCorrectlyDetected()
314 }).when(mSensorManager) in testDeviceIsNotOnEarWithProxNotSensed()
318 verify(mSensorManager).unregisterListener(any(SensorEventListener.class)); in testDeviceIsNotOnEarWithProxNotSensed()
335 }).when(mSensorManager) in testDeviceIsNotOnEarWithWrongOrientation()
339 verify(mSensorManager).unregisterListener(any(SensorEventListener.class)); in testDeviceIsNotOnEarWithWrongOrientation()
[all …]
/packages/apps/DevCamera/src/com/android/devcamera/
DGyroOperations.java32 private SensorManager mSensorManager; field in GyroOperations
46 mSensorManager = sensorManager; in GyroOperations()
50mSensorManager.registerListener(mSensorEventListener, mSensorManager.getDefaultSensor(Sensor.TYPE_… in startListening()
55 mSensorManager.unregisterListener(mSensorEventListener); in stopListening()
/packages/apps/Settings/tests/robotests/src/com/android/settings/gestures/
DDoubleTwistPreferenceControllerTest.java57 private SensorManager mSensorManager; field in DoubleTwistPreferenceControllerTest
79 when(mContext.getSystemService(Context.SENSOR_SERVICE)).thenReturn(mSensorManager); in isAvailable_hasSensor_shouldReturnTrue()
80 when(mSensorManager.getSensorList(anyInt())).thenReturn(sensorList); in isAvailable_hasSensor_shouldReturnTrue()
98 when(mContext.getSystemService(Context.SENSOR_SERVICE)).thenReturn(mSensorManager); in isAvailable_differentSensor_shouldReturnFalse()
99 when(mSensorManager.getSensorList(anyInt())).thenReturn(sensorList); in isAvailable_differentSensor_shouldReturnFalse()
/packages/services/Car/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/
DKitchenSinkActivity.java223 private CarSensorManager mSensorManager; field in KitchenSinkActivity
246 return mSensorManager; in getSensorManager()
408 mSensorManager = (CarSensorManager) car.getCarManager( in initManagers()
/packages/apps/LegacyCamera/src/com/android/camera/panorama/
DPanoramaActivity.java155 private SensorManager mSensorManager; field in PanoramaActivity
278 mSensorManager = (SensorManager) getSystemService(Context.SENSOR_SERVICE); in onCreate()
279 mSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_GYROSCOPE); in onCreate()
281 mSensor = mSensorManager.getDefaultSensor(Sensor.TYPE_ORIENTATION); in onCreate()