Fix alarm throttling.

Alarm throttling wasn't happening if the queue became empty before a new
alarm was scheduled. This fixes that so the min time between alarms is
always enforced.

Bug: 288975061
Test: atest FrameworksMockingServicesTests:AlarmQueueTest
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:ef46dcbc567938823b600eca5d3349d661a5aeaf)
Merged-In: Id01bcf4e7d53ae7d89c99cb7f97b86163c43ea88
Change-Id: Id01bcf4e7d53ae7d89c99cb7f97b86163c43ea88
2 files changed