From 3c3a29896f4a6e9d87c05c0990836afde228acc8 Mon Sep 17 00:00:00 2001 From: ByrmGkcn Date: Mon, 18 Dec 2023 16:21:38 +0100 Subject: [PATCH] add languages --- src/main/kotlin/main/Main.kt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/kotlin/main/Main.kt b/src/main/kotlin/main/Main.kt index 56e8e02..f916a9d 100644 --- a/src/main/kotlin/main/Main.kt +++ b/src/main/kotlin/main/Main.kt @@ -23,6 +23,7 @@ val customRedColor = Color(0xFFB70D1B) @Composable @Preview fun app() { + val languageManager = remember { LanguageManager() } MaterialTheme { val currentPage = remember { mutableStateOf("accueil") } @@ -46,6 +47,7 @@ fun app() { when (currentPage.value) { "accueil" -> { homePage( + languageManager, onGlossaryClick = { currentPage.value = "glossaires" }, onCodeToVerifyClick = { currentPage.value = "choixLangage" } ) @@ -199,6 +201,7 @@ fun app() { "glossaireOptions" -> { glossaryPage( + languageManager, onAddWordClick = { currentPage.value = "formulaire" }, onImportClick = { selectFile(setOf("csv", "xlsx")) { filePath -> @@ -244,6 +247,7 @@ fun app() { val javaExtensions = setOf("java") val jsExtensions = setOf("js", "html") choixLangagePage( + languageManager, onBackClick = { currentPage.value = "accueil" }, onPythonClick = { selectFile(pythonExtensions) { filePath ->