xetra11
12/25/2020, 9:41 PMfun main() {
Window(title = "CK3 Mod Workbench") {
MaterialTheme() {
val currentDialog = remember { mutableStateOf("noDialog") }
if (currentDialog.value == "characterDialog") Dialog(
onDismissRequest = { currentDialog.value = "noDialog" }
) {
Button(onClick = { currentDialog.value = "noDialog" }) {
Text("Close Dialog")
}
}
Button(onClick = { currentDialog.value = "characterDialog" }
) { Text("Open Dialog") }
}
}
}
I always end up with this exception preventing the dialog from being reopened:
Exception in thread "AWT-EventQueue-0" java.lang.IllegalArgumentException: Anchor refers to a group that was removed
Any idea what is going wrong here? I tried so many things but I just do not understand the problem.Kirill Grouchnikov
12/25/2020, 10:12 PMDominaezzz
12/25/2020, 10:15 PMxetra11
12/25/2020, 10:28 PMxetra11
12/25/2020, 10:29 PMIgor Demin
12/26/2020, 12:14 AMxetra11
12/26/2020, 10:37 AM