Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
Daniel 2025-10-23 12:50:42 +08:00
parent 9366b0f073
commit 59950dde41
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
3 changed files with 9 additions and 4 deletions

View file

@ -22,6 +22,10 @@ mac:
- NSMicrophoneUsageDescription: "This app requires microphone access to record audio." - NSMicrophoneUsageDescription: "This app requires microphone access to record audio."
entitlementsInherit: "../../entitlements.mas.plist" entitlementsInherit: "../../entitlements.mas.plist"
minimumSystemVersion: "10.15" minimumSystemVersion: "10.15"
protocols:
- name: "SiYuan"
schemes:
- "siyuan"
extraResources: extraResources:
- from: "kernel-darwin-arm64" - from: "kernel-darwin-arm64"
to: "kernel" to: "kernel"

View file

@ -22,6 +22,10 @@ mac:
- NSMicrophoneUsageDescription: "This app requires microphone access to record audio." - NSMicrophoneUsageDescription: "This app requires microphone access to record audio."
entitlementsInherit: "../../entitlements.mas.plist" entitlementsInherit: "../../entitlements.mas.plist"
minimumSystemVersion: "10.15" minimumSystemVersion: "10.15"
protocols:
- name: "SiYuan"
schemes:
- "siyuan"
extraResources: extraResources:
- from: "kernel-darwin" - from: "kernel-darwin"
to: "kernel" to: "kernel"

View file

@ -387,10 +387,7 @@ const initMainWindow = () => {
}); });
currentWindow.webContents.on("did-finish-load", () => { currentWindow.webContents.on("did-finish-load", () => {
let siyuanOpenURL; let siyuanOpenURL = process.argv.find((arg) => arg.startsWith("siyuan://"));
if ("win32" === process.platform || "linux" === process.platform) {
siyuanOpenURL = process.argv.find((arg) => arg.startsWith("siyuan://"));
}
if (siyuanOpenURL) { if (siyuanOpenURL) {
if (currentWindow.isMinimized()) { if (currentWindow.isMinimized()) {
currentWindow.restore(); currentWindow.restore();