Skip to content

PauseLab v1.3.2 — reliable system-alarm overlays

Latest

Choose a tag to compare

@JUSTICEKB JUSTICEKB released this 20 Jul 13:20

PauseLab v1.3.2 — System-alarm background trigger

This release fixes the case where a scheduled creature break appeared only after the user reopened PauseLab. The deadline is now owned by Android's alarm system rather than by a JavaScript page lifecycle or an in-process delayed callback.

What changed

  • Schedules a user-requested AlarmManager.setAlarmClock exact wake-up.
  • Delivers the deadline to an explicit, non-exported BroadcastReceiver.
  • Recreates the foreground overlay service from that receiver when the app process no longer exists.
  • Commits timer state before starting the live countdown service, so abrupt process reclamation cannot lose the deadline or selected effect settings.
  • Uses a short partial wake lock while the receiver hands work to the foreground service.
  • Restores pending alarms after device boot, app replacement, or a newly granted exact-alarm permission.
  • Keeps the focus service non-sticky: the system alarm is authoritative, while the service remains sticky only during the visible break overlay.

Verification

The debug APK was tested on an Android emulator using the real PauseLab UI:

  1. Granted Notifications, Display over other apps, and Alarms & reminders.
  2. Started a one-minute focus timer.
  3. Switched to Chrome.
  4. Killed the entire app.pauselab.mobile process with SIGKILL and confirmed no PauseLab PID remained.
  5. Confirmed the RTC_WAKEUP alarm still targeted app.pauselab.mobile.ALARM.
  6. At the exact deadline, Android created a new PauseLab process, delivered the broadcast, promoted the overlay service to a foreground service, and attached a TYPE_APPLICATION_OVERLAY window above Chrome without reopening PauseLab or tapping a notification.

Android compilation and Lint both pass with target SDK 35.

Install and test

Install PauseLab-Android-1.3.2-judging.apk, complete all three permission steps, set a short custom focus duration, tap Start focus, and switch to an ordinary app. Do not force-stop PauseLab in Android settings: force-stop is an explicit operating-system state that cancels an app's alarms until the user opens it again. On OEM Android variants with an Auto-start or Background protection control, allow PauseLab if the manufacturer blocks third-party alarm apps by default.

This APK uses a development signature for direct testing and hackathon judging, not app-store production distribution. Android intentionally hides third-party overlays on password, payment, system-security, and some anti-cheat screens.