XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet
公开
关注 0 Fork 0 Star 0
返回提交历史

SpaceEngineersModDev/SpaceEngineersBlueprintEditorInWinUI

完善剩余页面的en本地化

4767a60
XFE工作室室长 <mail@xfegzs.com>
提交于

代码差异

5 个文件 +26 -6
Modified SpaceEngineersBlueprintEditor/Model/BlueprintPropertyViewData.cs +1 -1
@@ -230,7 +230,7 @@ public partial class BlueprintPropertyViewData
230 230 }
231 231 catch (Exception ex)
232 232 {
233 GlobalServiceManager.GetService<IMessageService>()?.ShowMessage($"无法设置属性{Name}({Type?.Name})的值为{targetValue}:{ex.Message}", "错误", InfoBarSeverity.Error);
233 GlobalServiceManager.GetService<IMessageService>()?.ShowMessage($"{"Error_CantSetValue_CantSetProperty".GetLocalized()}{Name}({Type?.Name}){"Error_CantSetValue_ValueTo".GetLocalized()}{targetValue}: {ex.Message}", "Error".GetLocalized(), InfoBarSeverity.Error);
234 234 }
235 235 }
236 236
Modified SpaceEngineersBlueprintEditor/Strings/en-us/Resources.resw +20 -0
@@ -205,6 +205,14 @@
205 205 <value>Can't load definitions</value>
206 206 <comment>未能加载蓝图</comment>
207 207 </data>
208 <data name="Error_CantSetValue_CantSetProperty" xml:space="preserve">
209 <value>Can't set property</value>
210 <comment>无法设置属性</comment>
211 </data>
212 <data name="Error_CantSetValue_ValueTo" xml:space="preserve">
213 <value>'s value to</value>
214 <comment>的值为</comment>
215 </data>
208 216 <data name="Warning_BlueprintContainsNoFile" xml:space="preserve">
209 217 <value>Blueprint doesn't have any file (bp.sbc)</value>
210 218 <comment>该蓝图不包含蓝图文件(bp.sbc)</comment>
@@ -241,6 +249,10 @@
241 249 <value>Error</value>
242 250 <comment>错误</comment>
243 251 </data>
252 <data name="Error_Exception" xml:space="preserve">
253 <value>Exception error</value>
254 <comment>错误异常</comment>
255 </data>
244 256 <data name="Failed" xml:space="preserve">
245 257 <value>Failed</value>
246 258 <comment>失败</comment>
@@ -265,6 +277,14 @@
265 277 <value>Empty value</value>
266 278 <comment>空值</comment>
267 279 </data>
280 <data name="EmptyList" xml:space="preserve">
281 <value>Empty list</value>
282 <comment>空列表</comment>
283 </data>
284 <data name="Amount" xml:space="preserve">
285 <value>Amount</value>
286 <comment>数量</comment>
287 </data>
268 288 <data name="NullObject" xml:space="preserve">
269 289 <value>Null</value>
270 290 <comment>空对象</comment>
Modified SpaceEngineersBlueprintEditor/Utilities/Helpers/FileHelper.cs +1 -1
@@ -69,7 +69,7 @@ public static class FileHelper
69 69 /// <exception cref="DirectoryNotFoundException"></exception>
70 70 public static void CopyDirectory(string sourceDirectory, string targetDirectory, bool overwrite = false)
71 71 {
72 if (!Directory.Exists(sourceDirectory)) throw new DirectoryNotFoundException($"源目录未找到: {sourceDirectory}");
72 if (!Directory.Exists(sourceDirectory)) throw new DirectoryNotFoundException($"Can't find original directory: {sourceDirectory}");
73 73 if (!Directory.Exists(targetDirectory))
74 74 Directory.CreateDirectory(targetDirectory);
75 75 foreach (string file in Directory.GetFiles(sourceDirectory))
Renamed SpaceEngineersBlueprintEditor/Utilities/Helpers/Helper.cs +0 -0
此文件没有可显示的逐行差异。
Modified SpaceEngineersBlueprintEditor/Utilities/Helpers/SpaceEngineersHelper.cs +4 -4
@@ -125,7 +125,7 @@ public static class SpaceEngineersHelper
125 125 blueprintPropertyViewData.Children.Add(new()
126 126 {
127 127 Type = type,
128 Name = $"错误异常:{ex.Message}",
128 Name = $"{"Error_Exception".GetLocalized()}: {ex.Message}",
129 129 Parent = blueprintPropertyViewData
130 130 });
131 131 }
@@ -143,7 +143,7 @@ public static class SpaceEngineersHelper
143 143 {
144 144 blueprintPropertyViewData.Children.Add(new()
145 145 {
146 Name = "空对象",
146 Name = "NullObject".GetLocalized(),
147 147 Parent = blueprintPropertyViewData
148 148 });
149 149 return true;
@@ -226,14 +226,14 @@ public static class SpaceEngineersHelper
226 226 {
227 227 if (value is null)
228 228 {
229 blueprintPropertyViewData.CustomData = "空列表";
229 blueprintPropertyViewData.CustomData = "EmptyList".GetLocalized();
230 230 }
231 231 else
232 232 {
233 233 var count = 0;
234 234 foreach (var item in (IEnumerable)value)
235 235 count++;
236 blueprintPropertyViewData.CustomData = $"数量:{count}";
236 blueprintPropertyViewData.CustomData = $"{"Amount".GetLocalized()}: {count}";
237 237 }
238 238 }
239 239 else