Add trace points for measuring performance

Test: systrace
Bug: 139363827
Bug: 139360025
Change-Id: I979c5fbecbaa9896a39abeb7b5639a95a5166688
This commit is contained in:
Lucas Dupin
2019-10-08 11:44:42 -07:00
parent 3b5eb58b74
commit c989d983ec

View File

@@ -154,13 +154,17 @@ public class KeyguardStateControllerImpl extends KeyguardUpdateMonitorCallback
}
private void notifyKeyguardChanged() {
Trace.beginSection("KeyguardStateController#notifyKeyguardChanged");
// Copy the list to allow removal during callback.
new ArrayList<>(mCallbacks).forEach(Callback::onKeyguardShowingChanged);
Trace.endSection();
}
private void notifyUnlockedChanged() {
Trace.beginSection("KeyguardStateController#notifyUnlockedChanged");
// Copy the list to allow removal during callback.
new ArrayList<>(mCallbacks).forEach(Callback::onUnlockedChanged);
Trace.endSection();
}
@Override