feat(android): add reminders and background sync

- Add local overdue reminders with notification channel and tap-to-date\n- Extract shared sync engine for foreground and WorkManager sync\n- Schedule 15-minute sync/reminder work and restore tasks after boot\n- Request notification permission and document Android background limits
This commit is contained in:
Misaki
2026-10-26 21:02:55 +08:00
parent 082c1229f9
commit 121e66d527
21 changed files with 421 additions and 50 deletions
@@ -6,6 +6,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder
import com.google.android.material.materialswitch.MaterialSwitch
import com.google.android.material.textfield.TextInputEditText
import com.misaki.schedule.R
import com.misaki.schedule.background.BackgroundScheduler
import com.misaki.schedule.data.Prefs
import com.misaki.schedule.sync.SyncManager
@@ -24,6 +25,7 @@ object SettingsDialog {
.setPositiveButton(R.string.save) { _, _ ->
prefs.serverUrl = url.text?.toString().orEmpty()
prefs.enabled = enabled.isChecked
BackgroundScheduler.update(context, prefs)
syncManager.reload()
}
.show()