Check apps idle states on time changes am: c465e71cdc

am: d4bd4cb4b1

* commit 'd4bd4cb4b1faa8663cc8dde4d9bab15a9ec764d3':
  Check apps idle states on time changes
This commit is contained in:
Amith Yamasani
2016-01-22 20:58:46 +00:00
committed by android-build-merger

View File

@@ -557,6 +557,7 @@ public class UsageStatsService extends SystemService implements
}
mRealTimeSnapshot = actualRealtime;
mSystemTimeSnapshot = actualSystemTime;
postCheckIdleStates(UserHandle.USER_ALL);
}
return actualSystemTime;
}
@@ -601,7 +602,7 @@ public class UsageStatsService extends SystemService implements
|| event.mEventType == Event.SYSTEM_INTERACTION
|| event.mEventType == Event.USER_INTERACTION)) {
if (previouslyIdle) {
// Slog.d(TAG, "Informing listeners of out-of-idle " + event.mPackage);
//Slog.d(TAG, "Informing listeners of out-of-idle " + event.mPackage);
mHandler.sendMessage(mHandler.obtainMessage(MSG_INFORM_LISTENERS, userId,
/* idle = */ 0, event.mPackage));
notifyBatteryStats(event.mPackage, userId, false);