Massive/android/app/src/main/java/com/massive/StopTimer.kt

18 lines
570 B
Kotlin
Raw Normal View History

2022-07-05 03:33:42 +00:00
package com.massive
import android.app.Service
import android.content.Intent
import android.os.IBinder
import android.util.Log
2022-07-05 03:33:42 +00:00
class StopTimer : Service() {
override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
applicationContext.stopService(Intent(applicationContext, TimerService::class.java))
applicationContext.stopService(Intent(applicationContext, AlarmService::class.java))
2022-07-05 03:33:42 +00:00
return super.onStartCommand(intent, flags, startId)
}
override fun onBind(p0: Intent?): IBinder? {
return null
}
}