Skip to content
Commit 2d36b04d authored by dshivangi's avatar dshivangi
Browse files

Check 'DeviceFoldStateProvider' is already started

Start 'DeviceFoldStateProvider' only if it is not already started.

* There were multiple calls to start(), resulting in multiple calls to notifyFoldUpdate() for each event.
* Some calls to notifyFoldUpdate() were delayed and hence updated the value of lastHingeAngleBeforeTransition to incorrect values that blocked animation for Notification Shade.
* This change decreased the flakiness of StatusBarFoldAnimationTest from 30 to 0% (https://android-build.googleplex.com/builds/abtd/run/L52400000961960941)

Bug: 286514755
Test: StatusBarFoldAnimationTest
Change-Id: I3e268a1449f83afbda233906ff36a376a0f7f226
parent 4b8e8ea3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment