From 2d57c3f7c18bb82d721ae5995495c7221e6f9f4b Mon Sep 17 00:00:00 2001 From: Acaki Date: Thu, 14 Aug 2025 20:11:59 +0800 Subject: [PATCH] feat: add translations for new settings --- VoidLink/Localization/Localizable.xcstrings | 167 ++++++++++++++++++ .../ViewControllers/SettingsViewController.m | 4 +- VoidLink/mul.lproj/iPad.xcstrings | 76 +++++++- VoidLink/mul.lproj/iPhone.xcstrings | 58 +++++- 4 files changed, 299 insertions(+), 6 deletions(-) diff --git a/VoidLink/Localization/Localizable.xcstrings b/VoidLink/Localization/Localizable.xcstrings index 30fa6670..e373e237 100644 --- a/VoidLink/Localization/Localizable.xcstrings +++ b/VoidLink/Localization/Localizable.xcstrings @@ -3889,6 +3889,35 @@ } } }, + "renderingBackendStackTip" : { + "extractionState" : "manual", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "translated", + "value" : "Performance rendering mode can handle higher bitrate (>200mbps) with lower latency, the battery usage can be higher and PiP is not supported in this mode. Use balanced mode when issues occurred." + } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "性能渲染模式可以处理更高的比特率(>200mbps)和更低的延迟,但电池消耗可能更高,且该模式不支持画中画。如遇到问题请使用平衡模式。" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能渲染模式可以處理更高的位元速率(>200mbps)和更低的延遲,但電池消耗可能更高,且該模式不支援子母畫面。如遇到問題請使用平衡模式。" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能渲染模式可以處理更高的位元速率(>200mbps)和更低的延遲,但電池消耗可能更高,且該模式不支援子母畫面。如遇到問題請使用平衡模式。" + } + } + } + }, "Resume App" : { "extractionState" : "manual", "localizations" : { @@ -5200,6 +5229,144 @@ } } }, + "Rendering Mode (Experimental)" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(实验性)" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" + } + } + } + }, + "Frames to Buffer" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "缓冲帧数" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數" + } + } + } + }, + "Frames to buffer: %ld" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "缓冲帧数:%ld" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數:%ld" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數:%ld" + } + } + } + }, + "Performance Graphs - Opacity: %ld%%" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "性能图表 - 不透明度:%ld%%" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能圖表 - 不透明度:%ld%%" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能圖表 - 不透明度:%ld%%" + } + } + } + }, + "Balanced" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + } + } + }, + "Performance" : { + "extractionState" : "manual", + "localizations" : { + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "性能" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } + } + } + }, "闽ICP备17012590号-3A\n主办单位:福州创图信息技术有限公司" : { } diff --git a/VoidLink/ViewControllers/SettingsViewController.m b/VoidLink/ViewControllers/SettingsViewController.m index 1027a223..1f6aece5 100644 --- a/VoidLink/ViewControllers/SettingsViewController.m +++ b/VoidLink/ViewControllers/SettingsViewController.m @@ -2151,7 +2151,7 @@ BOOL isCustomResolution(int resolutionSelected) { } - (void) updateFrameQueueSizeText { - [self.frameQueueSizeLabel setText:[NSString stringWithFormat:@"Frames to buffer: %ld", _frameQueueSize ]]; + [self.frameQueueSizeLabel setText:[NSString stringWithFormat:NSLocalizedString(@"Frames to buffer: %ld", @"Frames to buffer label"), _frameQueueSize ]]; } - (void) enableGraphsChanged { @@ -2165,7 +2165,7 @@ BOOL isCustomResolution(int resolutionSelected) { } - (void) updateGraphOpacityText { - [self.enableGraphsLabel setText:[NSString stringWithFormat:@"Performance Graphs - Opacity: %ld%%", _graphOpacity ]]; + [self.enableGraphsLabel setText:[NSString stringWithFormat:NSLocalizedString(@"Performance Graphs - Opacity: %ld%%", @"Performance graphs opacity label"), _graphOpacity ]]; } - (void) saveSettings { diff --git a/VoidLink/mul.lproj/iPad.xcstrings b/VoidLink/mul.lproj/iPad.xcstrings index b5a45807..947d689d 100644 --- a/VoidLink/mul.lproj/iPad.xcstrings +++ b/VoidLink/mul.lproj/iPad.xcstrings @@ -418,6 +418,24 @@ "state" : "new", "value" : "Balanced" } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } } } }, @@ -430,6 +448,24 @@ "state" : "new", "value" : "Performance" } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "性能" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } } } }, @@ -958,6 +994,24 @@ "state" : "new", "value" : "Frames to Buffer" } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "缓冲帧数" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "緩衝影格數" + } } } }, @@ -3176,13 +3230,31 @@ } }, "v8l-hf-kiR.text" : { - "comment" : "Class = \"UILabel\"; text = \"Rendering Mode\"; ObjectID = \"v8l-hf-kiR\";", + "comment" : "Class = \"UILabel\"; text = \"Rendering Mode (Experimental)\"; ObjectID = \"v8l-hf-kiR\";", "extractionState" : "extracted_with_value", "localizations" : { "en" : { "stringUnit" : { "state" : "new", - "value" : "Rendering Mode" + "value" : "Rendering Mode (Experimental)" + } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(实验性)" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" } } } diff --git a/VoidLink/mul.lproj/iPhone.xcstrings b/VoidLink/mul.lproj/iPhone.xcstrings index 717c945b..43103409 100644 --- a/VoidLink/mul.lproj/iPhone.xcstrings +++ b/VoidLink/mul.lproj/iPhone.xcstrings @@ -706,6 +706,24 @@ "state" : "new", "value" : "Balanced" } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "平衡" + } } } }, @@ -718,6 +736,24 @@ "state" : "new", "value" : "Performance" } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "性能" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "效能" + } } } }, @@ -3188,13 +3224,31 @@ } }, "v8l-hf-kiR.text" : { - "comment" : "Class = \"UILabel\"; text = \"Rendering Mode\"; ObjectID = \"v8l-hf-kiR\";", + "comment" : "Class = \"UILabel\"; text = \"Rendering Mode (Experimental)\"; ObjectID = \"v8l-hf-kiR\";", "extractionState" : "extracted_with_value", "localizations" : { "en" : { "stringUnit" : { "state" : "new", - "value" : "Rendering Mode" + "value" : "Rendering Mode (Experimental)" + } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(实验性)" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" + } + }, + "zh-HK" : { + "stringUnit" : { + "state" : "translated", + "value" : "渲染模式(實驗性)" } } }