Merge "Update major/minor from longpress sensor" into sc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
ff8bdd8808
@@ -307,7 +307,7 @@ public class DozeTriggers implements DozeMachine.Part {
|
||||
// Since the gesture won't be received by the UDFPS view, manually inject an
|
||||
// event.
|
||||
mAuthController.onAodInterrupt((int) screenX, (int) screenY,
|
||||
rawValues[2] /* major */, rawValues[3] /* minor */);
|
||||
rawValues[3] /* major */, rawValues[4] /* minor */);
|
||||
} else {
|
||||
mDozeHost.extendPulse(pulseReason);
|
||||
}
|
||||
|
||||
@@ -236,13 +236,14 @@ public class DozeTriggersTest extends SysuiTestCase {
|
||||
public void testOnSensor_Fingerprint() {
|
||||
final int screenX = 100;
|
||||
final int screenY = 100;
|
||||
final float misc = -1;
|
||||
final float minor = 2f;
|
||||
final float major = 3f;
|
||||
final int reason = DozeLog.REASON_SENSOR_UDFPS_LONG_PRESS;
|
||||
float[] rawValues = new float[]{screenX, screenY, minor, major};
|
||||
float[] rawValues = new float[]{screenX, screenY, misc, major, minor};
|
||||
mTriggers.onSensor(reason, screenX, screenY, rawValues);
|
||||
verify(mHost).extendPulse(reason);
|
||||
verify(mAuthController).onAodInterrupt(eq(screenX), eq(screenY), eq(minor), eq(major));
|
||||
verify(mAuthController).onAodInterrupt(eq(screenX), eq(screenY), eq(major), eq(minor));
|
||||
}
|
||||
|
||||
private void waitForSensorManager() {
|
||||
|
||||
Reference in New Issue
Block a user