Add goida for ukrain people
This commit is contained in:
parent
cb3974bf6b
commit
6f3350b44c
2 changed files with 33 additions and 0 deletions
|
|
@ -72,6 +72,14 @@ fun MainAppScreen(vm: MainViewModel) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LaunchedEffect(vm.inoagentModeActive) {
|
||||||
|
if (vm.inoagentModeActive) {
|
||||||
|
vm.showInoagentDialog = true
|
||||||
|
delay(2000)
|
||||||
|
exitProcess(0)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
val imageLoader = remember {
|
val imageLoader = remember {
|
||||||
ImageLoader.Builder(ctx)
|
ImageLoader.Builder(ctx)
|
||||||
.components {
|
.components {
|
||||||
|
|
@ -160,6 +168,16 @@ fun MainAppScreen(vm: MainViewModel) {
|
||||||
icon = { Icon(Icons.Default.Star, contentDescription = null, tint = Color.Red) },
|
icon = { Icon(Icons.Default.Star, contentDescription = null, tint = Color.Red) },
|
||||||
modifier = Modifier.padding(NavigationDrawerItemDefaults.ItemPadding)
|
modifier = Modifier.padding(NavigationDrawerItemDefaults.ItemPadding)
|
||||||
)
|
)
|
||||||
|
NavigationDrawerItem(
|
||||||
|
label = { Text("ПОТУЖНОСТІ🇺🇦", color = Color.Blue, style = MaterialTheme.typography.titleMedium) },
|
||||||
|
selected = false,
|
||||||
|
onClick = {
|
||||||
|
scope.launch { drawerState.close() }
|
||||||
|
vm.startInoagentMode()
|
||||||
|
},
|
||||||
|
icon = { Icon(Icons.Default.BrightnessLow, contentDescription = null, tint = Color.Blue) },
|
||||||
|
modifier = Modifier.padding(NavigationDrawerItemDefaults.ItemPadding)
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
) {
|
) {
|
||||||
|
|
@ -459,4 +477,12 @@ fun MainAppScreen(vm: MainViewModel) {
|
||||||
confirmButton = {}
|
confirmButton = {}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (vm.showInoagentDialog) {
|
||||||
|
AlertDialog(
|
||||||
|
onDismissRequest = {},
|
||||||
|
title = { Text("ИНОАГЕНТ ОБНАРУЖЕН БЫСТРО В БУСИК", style = MaterialTheme.typography.headlineLarge, color = Color.Blue) },
|
||||||
|
confirmButton = {}
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,9 @@ class MainViewModel(appContext: Context) : ViewModel() {
|
||||||
var patriotModeActive by mutableStateOf(false)
|
var patriotModeActive by mutableStateOf(false)
|
||||||
var showPatriotDialog by mutableStateOf(false)
|
var showPatriotDialog by mutableStateOf(false)
|
||||||
|
|
||||||
|
var inoagentModeActive by mutableStateOf(false)
|
||||||
|
var showInoagentDialog by mutableStateOf(false)
|
||||||
|
|
||||||
init {
|
init {
|
||||||
if (isAuthenticated) {
|
if (isAuthenticated) {
|
||||||
checkRoleAndRestore()
|
checkRoleAndRestore()
|
||||||
|
|
@ -283,6 +286,10 @@ class MainViewModel(appContext: Context) : ViewModel() {
|
||||||
patriotModeActive = true
|
patriotModeActive = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fun startInoagentMode() {
|
||||||
|
inoagentModeActive = true
|
||||||
|
}
|
||||||
|
|
||||||
fun deleteBotPhrase(id: Int) {
|
fun deleteBotPhrase(id: Int) {
|
||||||
viewModelScope.launch {
|
viewModelScope.launch {
|
||||||
try {
|
try {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue