Marc
11/10/2023, 10:52 AM2023-11-10 11:47:59.224 java[34638:8397728] WARNING: Secure coding is not enabled for restorable state! Enable secure coding by implementing NSApplicationDelegate.applicationSupportsSecureRestorableState: and returning YES.
Exception in thread "main" java.lang.UnsatisfiedLinkError: 'long org.jetbrains.skiko.MetalApiKt.chooseAdapter(int)'
Somebody knows where this error could come from?Marc
11/10/2023, 1:33 PM@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun HomeScreen(
cacheFile: File?
) {
val properties = cacheFile?.let { propertyFile ->
val properties = Properties()
properties.load(propertyFile.inputStream())
properties
}
val lastPath = properties?.get("lastPath")?.toString()
var pickedPath by remember { mutableStateOf(lastPath) }
var directoryPickerOpen by remember { mutableStateOf(false) }
Column(
modifier = Modifier.fillMaxSize(),
horizontalAlignment = Alignment.CenterHorizontally,
verticalArrangement = Arrangement.Center
) {
OutlinedTextField(
modifier = Modifier.width(TextFieldDefaults.MinWidth * 3),
value = pickedPath ?: "",
onValueChange = { pickedPath = it },
trailingIcon = {
Icon(
imageVector = Icons.Default.Folder,
contentDescription = "Choose folder"
)
}
)
}
DirectoryPicker(
show = directoryPickerOpen,
initialDirectory = pickedPath
) {
pickedPath = it
directoryPickerOpen = false
}
}
Alexander Maryanovsky
11/10/2023, 4:08 PMAlexander Maryanovsky
11/10/2023, 4:10 PMMarc
11/10/2023, 4:40 PMMarc
11/13/2023, 9:25 AMMarc
11/13/2023, 9:26 AMAlexander Maryanovsky
11/13/2023, 9:35 AMAlexander Maryanovsky
11/13/2023, 9:36 AMDirectoryPicker
?Marc
11/13/2023, 9:38 AMMarc
11/13/2023, 9:38 AMdependencies {
// Note, if you develop a library, you should use compose.desktop.common.
// compose.desktop.currentOs should be used in launcher-sourceSet
// (in a separate module for demo project and in testMain).
// With compose.desktop.common you will also lose @Preview functionality
implementation(compose.desktop.currentOs) {
exclude("org.jetbrains.compose.material")
}
implementation(compose.material3)
implementation(compose.materialIconsExtended)
implementation("com.darkrockstudios:mpfilepicker:2.1.0") {
exclude("org.jetbrains.compose.material")
}
implementation(project("api"))
}
Alexander Maryanovsky
11/13/2023, 9:40 AMAlexander Maryanovsky
11/13/2023, 9:41 AMMarc
11/13/2023, 9:49 AMMarc
11/13/2023, 9:49 AMMarc
11/13/2023, 9:54 AMMarc
11/13/2023, 9:54 AMAlexander Maryanovsky
11/13/2023, 9:54 AM