From e8602cc52039c7ed02c7e05e75ebebdf999a9b0c Mon Sep 17 00:00:00 2001 From: jasonOu <277023606@qq.com> Date: Tue, 21 Jul 2020 16:44:21 +0800 Subject: [PATCH] Update I18nFileGenerator.kt MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix order unbalanced when have multiple parameter(text direction contain right-to-left) --- .../kotlin/eu/long1/flutter/i18n/workers/I18nFileGenerator.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/kotlin/eu/long1/flutter/i18n/workers/I18nFileGenerator.kt b/src/main/kotlin/eu/long1/flutter/i18n/workers/I18nFileGenerator.kt index fdcadc4..a3ea672 100644 --- a/src/main/kotlin/eu/long1/flutter/i18n/workers/I18nFileGenerator.kt +++ b/src/main/kotlin/eu/long1/flutter/i18n/workers/I18nFileGenerator.kt @@ -196,7 +196,7 @@ class I18nFileGenerator(private val project: Project) { var hasItems = false while (PARAMETER_MATCHER.find()) { if (!hasItems) { - builder.append(" String $id(") + builder.append(" String $id({") hasItems = true } @@ -206,7 +206,7 @@ class I18nFileGenerator(private val project: Project) { if (hasItems) { builder.setLength(builder.length - 2) - builder.append(")") + builder.append("})") } else { builder.append(" String get $id") }