Skip to content

Commit

Permalink
PowerToys v0.81.0 Translation v21.3 Incremental Pack
Browse files Browse the repository at this point in the history
  • Loading branch information
zetaloop committed May 24, 2024
1 parent 1925244 commit 22d49db
Show file tree
Hide file tree
Showing 35 changed files with 1,239 additions and 804 deletions.
2 changes: 1 addition & 1 deletion PowerToys/src/Version.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Version>0.80.0</Version>
<Version>0.81.0</Version>

<!-- Forcing for every DLL on by default -->
<ChecksumAlgorithm>SHA256</ChecksumAlgorithm>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@
var wrap = ([[PT_WRAP]] == 1) ? true : false;

var base64code = "[[PT_CODE]]";

var stickyScroll = ([[PT_STICKY_SCROLL]] == 1) ? true : false;

var fontSize = [[PT_FONT_SIZE]];

// Code taken from https://stackoverflow.com/a/30106551/14774889
var code = decodeURIComponent(atob(base64code).split('').map(function(c) {
Expand Down Expand Up @@ -57,7 +61,6 @@
var editor;
import { registerAdditionalLanguages } from "http://[[PT_URL]]/monacoSpecialLanguages.js"
require.config({ paths: { vs: 'http://[[PT_URL]]/monacoSRC/min/vs' } });
require.config({ 'vs/nls': { availableLanguages: { '*': 'zh-cn' } } }); // Thx https://github.com/microsoft/monaco-editor/issues/2320
require(['vs/editor/editor.main'], async function () {
await registerAdditionalLanguages(monaco)
// Creates the editor
Expand All @@ -78,6 +81,8 @@
horizontal: 'auto',

},
stickyScroll: {enabled: stickyScroll},
fontSize: fontSize,
wordWrap: (wrap?"on":"off") // Word wraps
});
window.onresize = function (){
Expand Down
12 changes: 12 additions & 0 deletions PowerToys/src/common/interop/interop.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,18 @@ public
return gcnew String(CommonSharedConstants::SHOW_COLOR_PICKER_SHARED_EVENT);
}

static String ^ ShowAdvancedPasteSharedEvent() {
return gcnew String(CommonSharedConstants::SHOW_ADVANCED_PASTE_SHARED_EVENT);
}

static String ^ AdvancedPasteMarkdownEvent() {
return gcnew String(CommonSharedConstants::ADVANCED_PASTE_MARKDOWN_EVENT);
}

static String ^ AdvancedPasteJsonEvent() {
return gcnew String(CommonSharedConstants::ADVANCED_PASTE_JSON_EVENT);
}

static String ^ ShowPowerOCRSharedEvent() {
return gcnew String(CommonSharedConstants::SHOW_POWEROCR_SHARED_EVENT);
}
Expand Down
72 changes: 36 additions & 36 deletions PowerToys/src/common/interop/keyboard_layout.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#include "pch.h"
#include "pch.h"
#include <array>
#include <algorithm>

Expand Down Expand Up @@ -108,7 +108,7 @@ void LayoutMap::LayoutMapImpl::UpdateLayout()
}

// Store the virtual key code as string
std::wstring vk = L"虚拟键值 ";
std::wstring vk = L"虚拟键值 ";
vk += std::to_wstring(i);
keyboardLayoutMap[i] = vk;
if (!isKeyCodeListGenerated)
Expand Down Expand Up @@ -143,39 +143,39 @@ void LayoutMap::LayoutMapImpl::UpdateLayout()
keyboardLayoutMap[VK_END] = L"End";
keyboardLayoutMap[VK_RETURN] = L"Enter";

keyboardLayoutMap[VK_LEFT | numpadOriginBit] = L"Left (小键盘)";
keyboardLayoutMap[VK_RIGHT | numpadOriginBit] = L"Right (小键盘)";
keyboardLayoutMap[VK_UP | numpadOriginBit] = L"Up (小键盘)";
keyboardLayoutMap[VK_DOWN | numpadOriginBit] = L"Down (小键盘)";
keyboardLayoutMap[VK_INSERT | numpadOriginBit] = L"Insert (小键盘)";
keyboardLayoutMap[VK_DELETE | numpadOriginBit] = L"Delete (小键盘)";
keyboardLayoutMap[VK_PRIOR | numpadOriginBit] = L"PgUp (小键盘)";
keyboardLayoutMap[VK_NEXT | numpadOriginBit] = L"PgDn (小键盘)";
keyboardLayoutMap[VK_HOME | numpadOriginBit] = L"Home (小键盘)";
keyboardLayoutMap[VK_END | numpadOriginBit] = L"End (小键盘)";
keyboardLayoutMap[VK_RETURN | numpadOriginBit] = L"Enter (小键盘)";
keyboardLayoutMap[VK_DIVIDE | numpadOriginBit] = L"/ (小键盘)";
keyboardLayoutMap[VK_LEFT | numpadOriginBit] = L"Left (小键盘)";
keyboardLayoutMap[VK_RIGHT | numpadOriginBit] = L"Right (小键盘)";
keyboardLayoutMap[VK_UP | numpadOriginBit] = L"Up (小键盘)";
keyboardLayoutMap[VK_DOWN | numpadOriginBit] = L"Down (小键盘)";
keyboardLayoutMap[VK_INSERT | numpadOriginBit] = L"Insert (小键盘)";
keyboardLayoutMap[VK_DELETE | numpadOriginBit] = L"Delete (小键盘)";
keyboardLayoutMap[VK_PRIOR | numpadOriginBit] = L"PgUp (小键盘)";
keyboardLayoutMap[VK_NEXT | numpadOriginBit] = L"PgDn (小键盘)";
keyboardLayoutMap[VK_HOME | numpadOriginBit] = L"Home (小键盘)";
keyboardLayoutMap[VK_END | numpadOriginBit] = L"End (小键盘)";
keyboardLayoutMap[VK_RETURN | numpadOriginBit] = L"Enter (小键盘)";
keyboardLayoutMap[VK_DIVIDE | numpadOriginBit] = L"/ (小键盘)";

keyboardLayoutMap[VK_SUBTRACT] = L"- (小键盘)";
keyboardLayoutMap[VK_SUBTRACT] = L"- (小键盘)";
keyboardLayoutMap[VK_SELECT] = L"Select";
keyboardLayoutMap[VK_PRINT] = L"Print";
keyboardLayoutMap[VK_EXECUTE] = L"Execute";
keyboardLayoutMap[VK_SNAPSHOT] = L"Print Screen";
keyboardLayoutMap[VK_HELP] = L"Help";
keyboardLayoutMap[VK_LWIN] = L"Win (左)";
keyboardLayoutMap[VK_RWIN] = L"Win (右)";
keyboardLayoutMap[VK_LWIN] = L"Win (左)";
keyboardLayoutMap[VK_RWIN] = L"Win (右)";
keyboardLayoutMap[VK_APPS] = L"Apps/Menu";
keyboardLayoutMap[VK_SLEEP] = L"Sleep";
keyboardLayoutMap[VK_NUMPAD0] = L"0 (小键盘)";
keyboardLayoutMap[VK_NUMPAD1] = L"1 (小键盘)";
keyboardLayoutMap[VK_NUMPAD2] = L"2 (小键盘)";
keyboardLayoutMap[VK_NUMPAD3] = L"3 (小键盘)";
keyboardLayoutMap[VK_NUMPAD4] = L"4 (小键盘)";
keyboardLayoutMap[VK_NUMPAD5] = L"5 (小键盘)";
keyboardLayoutMap[VK_NUMPAD6] = L"6 (小键盘)";
keyboardLayoutMap[VK_NUMPAD7] = L"7 (小键盘)";
keyboardLayoutMap[VK_NUMPAD8] = L"8 (小键盘)";
keyboardLayoutMap[VK_NUMPAD9] = L"9 (小键盘)";
keyboardLayoutMap[VK_NUMPAD0] = L"0 (小键盘)";
keyboardLayoutMap[VK_NUMPAD1] = L"1 (小键盘)";
keyboardLayoutMap[VK_NUMPAD2] = L"2 (小键盘)";
keyboardLayoutMap[VK_NUMPAD3] = L"3 (小键盘)";
keyboardLayoutMap[VK_NUMPAD4] = L"4 (小键盘)";
keyboardLayoutMap[VK_NUMPAD5] = L"5 (小键盘)";
keyboardLayoutMap[VK_NUMPAD6] = L"6 (小键盘)";
keyboardLayoutMap[VK_NUMPAD7] = L"7 (小键盘)";
keyboardLayoutMap[VK_NUMPAD8] = L"8 (小键盘)";
keyboardLayoutMap[VK_NUMPAD9] = L"9 (小键盘)";
keyboardLayoutMap[VK_SEPARATOR] = L"Separator";
keyboardLayoutMap[VK_F1] = L"F1";
keyboardLayoutMap[VK_F2] = L"F2";
Expand Down Expand Up @@ -203,12 +203,12 @@ void LayoutMap::LayoutMapImpl::UpdateLayout()
keyboardLayoutMap[VK_F24] = L"F24";
keyboardLayoutMap[VK_NUMLOCK] = L"Num Lock";
keyboardLayoutMap[VK_SCROLL] = L"Scroll Lock";
keyboardLayoutMap[VK_LSHIFT] = L"Shift (左)";
keyboardLayoutMap[VK_RSHIFT] = L"Shift (右)";
keyboardLayoutMap[VK_LCONTROL] = L"Ctrl (左)";
keyboardLayoutMap[VK_RCONTROL] = L"Ctrl (右)";
keyboardLayoutMap[VK_LMENU] = L"Alt (左)";
keyboardLayoutMap[VK_RMENU] = L"Alt (右)";
keyboardLayoutMap[VK_LSHIFT] = L"Shift (左)";
keyboardLayoutMap[VK_RSHIFT] = L"Shift (右)";
keyboardLayoutMap[VK_LCONTROL] = L"Ctrl (左)";
keyboardLayoutMap[VK_RCONTROL] = L"Ctrl (右)";
keyboardLayoutMap[VK_LMENU] = L"Alt (左)";
keyboardLayoutMap[VK_RMENU] = L"Alt (右)";
keyboardLayoutMap[VK_BROWSER_BACK] = L"Browser Back";
keyboardLayoutMap[VK_BROWSER_FORWARD] = L"Browser Forward";
keyboardLayoutMap[VK_BROWSER_REFRESH] = L"Browser Refresh";
Expand Down Expand Up @@ -236,7 +236,7 @@ void LayoutMap::LayoutMapImpl::UpdateLayout()
keyboardLayoutMap[VK_ZOOM] = L"Zoom";
keyboardLayoutMap[VK_PA1] = L"PA1";
keyboardLayoutMap[VK_OEM_CLEAR] = L"Clear";
keyboardLayoutMap[0xFF] = L"未定义";
keyboardLayoutMap[0xFF] = L"未定义";
keyboardLayoutMap[CommonSharedConstants::VK_WIN_BOTH] = L"Win";
keyboardLayoutMap[VK_KANA] = L"IME Kana";
keyboardLayoutMap[VK_HANGEUL] = L"IME Hangeul";
Expand All @@ -249,8 +249,8 @@ void LayoutMap::LayoutMapImpl::UpdateLayout()
keyboardLayoutMap[VK_NONCONVERT] = L"IME Non-Convert";
keyboardLayoutMap[VK_ACCEPT] = L"IME Kana";
keyboardLayoutMap[VK_MODECHANGE] = L"IME Mode Change";
keyboardLayoutMap[VK_DECIMAL] = L". (小键盘)";
keyboardLayoutMap[CommonSharedConstants::VK_DISABLED] = L"空白";
keyboardLayoutMap[VK_DECIMAL] = L". (小键盘)";
keyboardLayoutMap[CommonSharedConstants::VK_DISABLED] = L"空白";
}

// Function to return the list of key codes in the order for the drop down. It creates it if it doesn't exist
Expand Down
19 changes: 10 additions & 9 deletions PowerToys/src/gpo/assets/zh-CN/PowerToys.adml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) Microsoft Corporation.
Licensed under the MIT License. -->
<policyDefinitionResources xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" revision="1.8" schemaVersion="1.0" xmlns="http://schemas.microsoft.com/GroupPolicy/2006/07/PolicyDefinitions">
<policyDefinitionResources xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" revision="1.9" schemaVersion="1.0" xmlns="http://schemas.microsoft.com/GroupPolicy/2006/07/PolicyDefinitions">
<displayName>PowerToys</displayName>
<description>PowerToys</description>
<resources>
Expand All @@ -19,8 +19,9 @@
<string id="SUPPORTED_POWERTOYS_0_76_0">PowerToys 版本 0.76.0 或更高版本</string>
<string id="SUPPORTED_POWERTOYS_0_77_0">PowerToys 版本 0.77.0 或更高版本</string>
<string id="SUPPORTED_POWERTOYS_0_78_0">PowerToys 版本 0.78.0 或更高版本</string>
<string id="SUPPORTED_POWERTOYS_0_81_0">PowerToys 版本 0.81.0 或更高版本</string>

<string id="ConfigureGlobalUtilityEnabledStateDescription">此策略控制所有 PowerToys 功能的启用状态。
<string id="ConfigureGlobalUtilityEnabledStateDescription">此策略控制所有 PowerToys 功能的启用状态。

如果策略设置为“已启用”,所有功能将始终启用,用户不可以禁用任何功能。

Expand All @@ -31,7 +32,7 @@
特定某个功能的启用状态策略将会覆盖此策略。
</string>

<string id="ConfigureEnabledUtilityDescription">此策略控制一个 PowerToys 功能的启用状态。
<string id="ConfigureEnabledUtilityDescription">此策略控制一个 PowerToys 功能的启用状态。

如果策略设置为“已启用”,该功能将始终启用,用户不可以禁用这个功能。

Expand Down Expand Up @@ -119,6 +120,7 @@
注意:更改需要重新启动快捷启动器才能应用。
</string>
<string id="ConfigureGlobalUtilityEnabledState">配置所有功能的启用状态</string>
<string id="ConfigureEnabledUtilityAdvancedPaste">高级粘贴: 启用该功能</string>
<string id="ConfigureEnabledUtilityAlwaysOnTop">窗口置顶: 启用该功能</string>
<string id="ConfigureEnabledUtilityAwake">阻止睡眠: 启用该功能</string>
<string id="ConfigureEnabledUtilityColorPicker">取色器: 启用该功能</string>
Expand All @@ -144,7 +146,6 @@
<string id="ConfigureEnabledUtilityMouseJump">鼠标工具箱 - 鼠标跳转: 启用该功能</string>
<string id="ConfigureEnabledUtilityMousePointerCrosshairs">鼠标工具箱 - 鼠标准心: 启用该功能</string>
<string id="ConfigureEnabledUtilityMouseWithoutBorders">无界鼠标: 启用该功能</string>
<string id="ConfigureEnabledUtilityPastePlain">纯文本粘贴: 启用该功能</string>
<string id="ConfigureEnabledUtilityPeek">快速查看: 启用该功能</string>
<string id="ConfigureEnabledUtilityPowerRename">批量重命名: 启用该功能</string>
<string id="ConfigureEnabledUtilityPowerLauncher">快捷启动器: 启用该功能</string>
Expand All @@ -165,13 +166,13 @@
<string id="ConfigureEnabledUtilityFileExplorerQOIPreview">预览增强 - QOI 文件预览: 启用该功能</string>
<string id="ConfigureEnabledUtilityFileExplorerQOIThumbnails">预览增强 - QOI 文件缩略图: 启用该功能</string>
</stringTable>
<presentationTable>
<presentation id="PowerToysRunIndividualPluginEnabledState">

<presentationTable>
<presentation id="PowerToysRunIndividualPluginEnabledState">
<listBox refId="PowerToysRunIndividualPluginEnabledList">插件管理列表:</listBox>
</presentation>
</presentationTable>
</presentationTable>

</resources>
</policyDefinitionResources>

Loading

0 comments on commit 22d49db

Please sign in to comment.