RadioAlarmExtensions.kt 708B

123456789101112131415161718192021222324252627282930313233
  1. package fr.forum_thalie.tsumugi.alarm
  2. import android.content.Context
  3. import android.content.Intent
  4. import fr.forum_thalie.tsumugi.Actions
  5. import fr.forum_thalie.tsumugi.RadioService
  6. fun playOnFallback(c: Context) {
  7. val a = Actions.PLAY_OR_FALLBACK
  8. val i = Intent(c, RadioService::class.java)
  9. i.putExtra("action", a.name)
  10. c.startService(i)
  11. }
  12. fun resume(c: Context)
  13. {
  14. }
  15. fun resumeStop(c: Context) {
  16. val a = Actions.PLAY
  17. val i = Intent(c, RadioService::class.java)
  18. i.putExtra("action", a.name)
  19. c.startService(i)
  20. }
  21. fun resumePlay(c: Context) {
  22. val a = Actions.PLAY
  23. val i = Intent(c, RadioService::class.java)
  24. i.putExtra("action", a.name)
  25. c.startService(i)
  26. }