16 lines
403 B
Kotlin
16 lines
403 B
Kotlin
package com.example.tvcontroller.ui
|
|
|
|
import androidx.compose.runtime.mutableStateOf
|
|
import androidx.lifecycle.ViewModel
|
|
|
|
class AppViewModel() : ViewModel() {
|
|
private var isBluetoothEnabled = mutableStateOf(false)
|
|
|
|
fun setBluetoothEnabled(enabled: Boolean) {
|
|
isBluetoothEnabled.value = enabled
|
|
}
|
|
|
|
fun isBluetoothEnabled(): Boolean {
|
|
return isBluetoothEnabled.value
|
|
}
|
|
} |