Files
MWClash/android/app/src/main/kotlin/com/follow/clash/TempActivity.kt

25 lines
619 B
Kotlin
Raw Normal View History

2024-04-30 23:38:49 +08:00
package com.follow.clash
import android.app.Activity
import android.os.Bundle
import com.follow.clash.extensions.wrapAction
2024-04-30 23:38:49 +08:00
class TempActivity : Activity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
when (intent.action) {
wrapAction("START") -> {
GlobalState.handleStart()
}
wrapAction("STOP") -> {
GlobalState.handleStop()
}
wrapAction("CHANGE") -> {
GlobalState.handleToggle()
}
}
2024-04-30 23:38:49 +08:00
finishAndRemoveTask()
}
}