From b50add39bdb74dfff93ec7e5fb5b0eb9770e345e Mon Sep 17 00:00:00 2001 From: tisfeng Date: Sat, 7 Sep 2024 11:06:28 +0800 Subject: [PATCH] fix: add NSAppleEventsUsageDescrip to info.plist to fix NSAppleScript unauthorized error (#669) * fix: add NSAppleEventsUsageDescrip to info.plist to fix unauthorized error * fix: add missing InfoPlist.xcstrings --- Easydict/App/Info-debug.plist | 2 ++ Easydict/App/Info.plist | 2 ++ Easydict/App/InfoPlist.xcstrings | 48 ++++++++++++++++++++++++++++++++ 3 files changed, 52 insertions(+) diff --git a/Easydict/App/Info-debug.plist b/Easydict/App/Info-debug.plist index ea4ccacdd..b7bbc4934 100644 --- a/Easydict/App/Info-debug.plist +++ b/Easydict/App/Info-debug.plist @@ -2,6 +2,8 @@ + NSAppleEventsUsageDescription + Easydict requires permission to execute AppleScript. CFBundleDevelopmentRegion $(DEVELOPMENT_LANGUAGE) CFBundleDisplayName diff --git a/Easydict/App/Info.plist b/Easydict/App/Info.plist index 924854355..dcb877f6c 100644 --- a/Easydict/App/Info.plist +++ b/Easydict/App/Info.plist @@ -2,6 +2,8 @@ + NSAppleEventsUsageDescription + Easydict requires permission to execute AppleScript. CFBundleDevelopmentRegion $(DEVELOPMENT_LANGUAGE) CFBundleDisplayName diff --git a/Easydict/App/InfoPlist.xcstrings b/Easydict/App/InfoPlist.xcstrings index 9bae7f6c3..3643696dc 100644 --- a/Easydict/App/InfoPlist.xcstrings +++ b/Easydict/App/InfoPlist.xcstrings @@ -11,6 +11,12 @@ "value" : "Easydict" } }, + "en-CA" : { + "stringUnit" : { + "state" : "translated", + "value" : "Easydict" + } + }, "zh-Hans" : { "stringUnit" : { "state" : "translated", @@ -35,6 +41,12 @@ "value" : "Easydict" } }, + "en-CA" : { + "stringUnit" : { + "state" : "translated", + "value" : "Easydict" + } + }, "zh-Hans" : { "stringUnit" : { "state" : "translated", @@ -49,6 +61,36 @@ } } }, + "NSAppleEventsUsageDescription" : { + "comment" : "Privacy - AppleEvents Sending Usage Description", + "extractionState" : "extracted_with_value", + "localizations" : { + "en" : { + "stringUnit" : { + "state" : "new", + "value" : "Easydict requires permission to execute AppleScript." + } + }, + "en-CA" : { + "stringUnit" : { + "state" : "translated", + "value" : "Easydict requires permission to execute AppleScript." + } + }, + "zh-Hans" : { + "stringUnit" : { + "state" : "translated", + "value" : "Easydict 需要权限来执行 AppleScript。" + } + }, + "zh-Hant" : { + "stringUnit" : { + "state" : "translated", + "value" : "Easydict 需要權限來執行 AppleScript。" + } + } + } + }, "NSHumanReadableCopyright" : { "comment" : "Copyright (human-readable)", "extractionState" : "extracted_with_value", @@ -59,6 +101,12 @@ "value" : "Copyright © 2023-2024 tisfeng. All rights reserved." } }, + "en-CA" : { + "stringUnit" : { + "state" : "translated", + "value" : "Copyright © 2023-2024 tisfeng. All rights reserved." + } + }, "zh-Hans" : { "stringUnit" : { "state" : "translated",