Click "add new device" and scan the QR code on the right
-
Bookmark connect.comma.ai to your home screen to use it like an app
+
%1
+
%2
+
%3
- )"), this);
+ )").arg(tr("Go to https://connect.comma.ai on your phone"))
+ .arg(tr("Click \"add new device\" and scan the QR code on the right"))
+ .arg(tr("Bookmark connect.comma.ai to your home screen to use it like an app")), this);
+
instructions->setStyleSheet("font-size: 47px; font-weight: bold; color: black;");
instructions->setWordWrap(true);
vlayout->addWidget(instructions);
diff --git a/selfdrive/ui/translations/main_ko.qm b/selfdrive/ui/translations/main_ko.qm
index 4c8b030327..4ba8cc0094 100644
--- a/selfdrive/ui/translations/main_ko.qm
+++ b/selfdrive/ui/translations/main_ko.qm
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:4e2338f5e74f7be0ef00229b0f30e3129dcd1eaa3f06b0f9ede3c2dc89a743d1
-size 19981
+oid sha256:fb7e26c65d5dee24c17532f9810a00e6a278f6f8f851bdd06418e4ed13fed213
+size 19439
diff --git a/selfdrive/ui/translations/main_ko.ts b/selfdrive/ui/translations/main_ko.ts
index 3805f0e3ff..2fefa69a80 100644
--- a/selfdrive/ui/translations/main_ko.ts
+++ b/selfdrive/ui/translations/main_ko.ts
@@ -308,13 +308,8 @@
- Need at least
- 최소
-
-
-
- characters!
- 자가 필요합니다!
+ Need at least %1 characters!
+ 최소 %1 자가 필요합니다!
@@ -481,8 +476,8 @@ location set
- for "
- 하기위한 "
+ for "%1"
+ 하기위한 "%1"
@@ -547,52 +542,50 @@ location set
장치를 콤마 계정과 페어링합니다
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>Go to https://connect.comma.ai on your phone</li>
- <li style='margin-bottom: 50px;'>Click "add new device" and scan the QR code on the right</li>
- <li style='margin-bottom: 50px;'>Bookmark connect.comma.ai to your home screen to use it like an app</li>
- </ol>
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>https://connect.comma.ai에 접속하세요</li>
- <li style='margin-bottom: 50px;'>"새 장치 추가"를 클릭하고 오른쪽 QR 코드를 검색합니다.</li>
- <li style='margin-bottom: 50px;'>connect.comma.ai을 앱처럼 사용하려면 홈 화면에 바로가기를 만드십시오.</li>
- </ol>
-
+
+ Go to https://connect.comma.ai on your phone
+ https://connect.comma.ai에 접속하세요
+
+
+
+ Click "add new device" and scan the QR code on the right
+ "새 장치 추가"를 클릭하고 오른쪽 QR 코드를 검색합니다
+
+
+
+ Bookmark connect.comma.ai to your home screen to use it like an app
+ connect.comma.ai을 앱처럼 사용하려면 홈 화면에 바로가기를 만드십시오PrimeAdWidget
-
+ Upgrade Now지금 업그레이드
-
+ Become a comma prime member at connect.comma.aiconnect.comma.ai에서 comma prime에 가입합니다
-
+ PRIME FEATURES:PRIME 기능:
-
+ Remote access원격 접속
-
+ 1 year of storage1년간 저장
-
+ Developer perks개발자 혜택
@@ -600,22 +593,22 @@ location set
PrimeUserWidget
-
+ ✓ SUBSCRIBED✓ 구독함
-
+ comma primecomma prime
-
+ CONNECT.COMMA.AICONNECT.COMMA.AI
-
+ COMMA POINTSCOMMA POINTS
@@ -857,17 +850,17 @@ location set
SetupWidget
-
+ Finish Setup설정 완료
-
+ Pair your device with comma connect (connect.comma.ai) and claim your comma prime offer.장치를 (connect.comma.ai)에서 페어링하고 comma prime 오퍼를 청구합니다.
-
+ Pair device장치 페어링
@@ -1023,13 +1016,13 @@ location set
- Uninstall
- 제거
+ UNINSTALL
+ 제거
- UNINSTALL
- 제거
+ Uninstall %1
+ 제거 %1
@@ -1274,8 +1267,8 @@ location set
- Forget Wi-Fi Network "
- wifi 네트워크 저장안함 "
+ Forget Wi-Fi Network "%1"?
+ wifi 네트워크 저장안함 "%1"?
diff --git a/selfdrive/ui/translations/main_zh-CHS.qm b/selfdrive/ui/translations/main_zh-CHS.qm
index 8b4a5f55f2..2976aa478b 100644
--- a/selfdrive/ui/translations/main_zh-CHS.qm
+++ b/selfdrive/ui/translations/main_zh-CHS.qm
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:6e042d706f1886874e0189b0542d4455050b59b6958e79ae03b563e35106e2be
-size 18469
+oid sha256:ddfc47a6fec5375c88f63275d02846cb7f4bf5431346cad895038a8705724ba3
+size 17931
diff --git a/selfdrive/ui/translations/main_zh-CHS.ts b/selfdrive/ui/translations/main_zh-CHS.ts
index d9377054a5..0870ff7028 100644
--- a/selfdrive/ui/translations/main_zh-CHS.ts
+++ b/selfdrive/ui/translations/main_zh-CHS.ts
@@ -308,13 +308,8 @@
- Need at least
- 至少需要
-
-
-
- characters!
- 个字符!
+ Need at least %1 characters!
+ 至少需要 %1 个字符!
@@ -479,8 +474,8 @@ location set
- for "
- 网络名称:"
+ for "%1"
+ 网络名称:"%1"
@@ -545,52 +540,50 @@ location set
将您的设备与comma账号配对
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>Go to https://connect.comma.ai on your phone</li>
- <li style='margin-bottom: 50px;'>Click "add new device" and scan the QR code on the right</li>
- <li style='margin-bottom: 50px;'>Bookmark connect.comma.ai to your home screen to use it like an app</li>
- </ol>
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>在手机上访问 https://connect.comma.ai</li>
- <li style='margin-bottom: 50px;'>点击“添加新设备”,扫描右侧二维码</li>
- <li style='margin-bottom: 50px;'>将 connect.comma.ai 收藏到您的主屏幕,以便像应用程序一样使用它</li>
- </ol>
-
+
+ Go to https://connect.comma.ai on your phone
+ 在手机上访问 https://connect.comma.ai
+
+
+
+ Click "add new device" and scan the QR code on the right
+ 点击“添加新设备”,扫描右侧二维码
+
+
+
+ Bookmark connect.comma.ai to your home screen to use it like an app
+ 将 connect.comma.ai 收藏到您的主屏幕,以便像应用程序一样使用它PrimeAdWidget
-
+ Upgrade Now现在升级
-
+ Become a comma prime member at connect.comma.ai打开connect.comma.ai以注册comma prime会员
-
+ PRIME FEATURES:comma prime特权:
-
+ Remote access远程访问
-
+ 1 year of storage1年数据存储
-
+ Developer perks开发者福利
@@ -598,22 +591,22 @@ location set
PrimeUserWidget
-
+ ✓ SUBSCRIBED✓ 已订阅
-
+ comma primecomma prime
-
+ CONNECT.COMMA.AICONNECT.COMMA.AI
-
+ COMMA POINTSCOMMA POINTS点数
@@ -855,17 +848,17 @@ location set
SetupWidget
-
+ Finish Setup完成设置
-
+ Pair your device with comma connect (connect.comma.ai) and claim your comma prime offer.将您的设备与comma connect (connect.comma.ai)配对并领取您的comma prime优惠。
-
+ Pair device配对设备
@@ -1021,13 +1014,13 @@ location set
- Uninstall
- 卸载
+ UNINSTALL
+ 卸载
- UNINSTALL
- 卸载
+ Uninstall %1
+ 卸载 %1
@@ -1272,8 +1265,8 @@ location set
- Forget Wi-Fi Network "
- 忘记WiFi网络"
+ Forget Wi-Fi Network "%1"?
+ 忘记WiFi网络 "%1"?
diff --git a/selfdrive/ui/translations/main_zh-CHT.qm b/selfdrive/ui/translations/main_zh-CHT.qm
index 0d71e0e187..b2b8f151a0 100644
--- a/selfdrive/ui/translations/main_zh-CHT.qm
+++ b/selfdrive/ui/translations/main_zh-CHT.qm
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:953e9b3373d9120e66da108eec0cb9689f7b2646229d4ea7c05e7b31392acbb2
-size 18509
+oid sha256:846dcae2af3d8071cdcfd1a20a65e06b7e7105cb128bae8b8244f2a29fe59dc4
+size 17969
diff --git a/selfdrive/ui/translations/main_zh-CHT.ts b/selfdrive/ui/translations/main_zh-CHT.ts
index efd893ec4c..0620382a63 100644
--- a/selfdrive/ui/translations/main_zh-CHT.ts
+++ b/selfdrive/ui/translations/main_zh-CHT.ts
@@ -308,13 +308,8 @@
- Need at least
- 需要至少
-
-
-
- characters!
- 個字元!
+ Need at least %1 characters!
+ 需要至少 %1 個字元!
@@ -481,8 +476,8 @@ location set
- for "
- 給 "
+ for "%1"
+ 給 "%1"
@@ -547,52 +542,50 @@ location set
將設備與您的 comma 帳號配對
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>Go to https://connect.comma.ai on your phone</li>
- <li style='margin-bottom: 50px;'>Click "add new device" and scan the QR code on the right</li>
- <li style='margin-bottom: 50px;'>Bookmark connect.comma.ai to your home screen to use it like an app</li>
- </ol>
-
-
- <ol type='1' style='margin-left: 15px;'>
- <li style='margin-bottom: 50px;'>用手機連至 https://connect.comma.ai</li>
- <li style='margin-bottom: 50px;'>點選 "add new device" 後掃描右邊的二維碼</li>
- <li style='margin-bottom: 50px;'>將 connect.comma.ai 加入您的主屏幕,以便像手機 App 一樣使用它</li>
- </ol>
-
+
+ Go to https://connect.comma.ai on your phone
+ 用手機連至 https://connect.comma.ai
+
+
+
+ Click "add new device" and scan the QR code on the right
+ 點選 "add new device" 後掃描右邊的二維碼
+
+
+
+ Bookmark connect.comma.ai to your home screen to use it like an app
+ 將 connect.comma.ai 加入您的主屏幕,以便像手機 App 一樣使用它PrimeAdWidget
-
+ Upgrade Now馬上升級
-
+ Become a comma prime member at connect.comma.ai成為 connect.comma.ai 的高級會員
-
+ PRIME FEATURES:高級會員特點:
-
+ Remote access遠程訪問
-
+ 1 year of storage一年的雲端行車記錄
-
+ Developer perks開發者福利
@@ -600,22 +593,22 @@ location set
PrimeUserWidget
-
+ ✓ SUBSCRIBED✓ 已訂閱
-
+ comma primecomma 高級會員
-
+ CONNECT.COMMA.AICONNECT.COMMA.AI
-
+ COMMA POINTSCOMMA 積分
@@ -860,17 +853,17 @@ location set
SetupWidget
-
+ Finish Setup完成設置
-
+ Pair your device with comma connect (connect.comma.ai) and claim your comma prime offer.將您的設備與 comma connect (connect.comma.ai) 配對並領取您的 comma 高級會員優惠。
-
+ Pair device配對設備
@@ -1026,13 +1019,13 @@ location set
- Uninstall
- 卸載
+ UNINSTALL
+ 卸載
- UNINSTALL
- 卸載
+ Uninstall %1
+ 卸載 %1
@@ -1277,8 +1270,8 @@ location set
- Forget Wi-Fi Network "
- 清除 Wi-Fi 網路 "
+ Forget Wi-Fi Network "%1"?
+ 清除 Wi-Fi 網路 "%1"?
diff --git a/selfdrive/ui/update_translations.py b/selfdrive/ui/update_translations.py
index d872be0d86..f06d54b2d5 100755
--- a/selfdrive/ui/update_translations.py
+++ b/selfdrive/ui/update_translations.py
@@ -10,7 +10,7 @@ TRANSLATIONS_DIR = os.path.join(UI_DIR, "translations")
LANGUAGES_FILE = os.path.join(TRANSLATIONS_DIR, "languages.json")
-def update_translations(release=False, translations_dir=TRANSLATIONS_DIR):
+def update_translations(release=False, vanish=False, translations_dir=TRANSLATIONS_DIR):
with open(LANGUAGES_FILE, "r") as f:
translation_files = json.load(f)
@@ -20,7 +20,10 @@ def update_translations(release=False, translations_dir=TRANSLATIONS_DIR):
continue
tr_file = os.path.join(translations_dir, f"{file}.ts")
- ret = os.system(f"lupdate -recursive {UI_DIR} -ts {tr_file}")
+ args = f"lupdate -recursive {UI_DIR} -ts {tr_file}"
+ if vanish:
+ args += " -no-obsolete"
+ ret = os.system(args)
assert ret == 0
if release:
@@ -32,6 +35,7 @@ if __name__ == "__main__":
parser = argparse.ArgumentParser(description="Update translation files for UI",
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
parser.add_argument("--release", action="store_true", help="Create compiled QM translation files used by UI")
+ parser.add_argument("--vanish", action="store_true", help="Remove translations with source text no longer found")
args = parser.parse_args()
- update_translations(args.release)
+ update_translations(args.release, args.vanish)