mirror of
https://github.com/A-Star100/simpliplay-desktop.git
synced 2025-09-17 22:29:38 +00:00
Update main.js
This commit is contained in:
parent
cc64b6969f
commit
75e388cffa
@ -181,6 +181,17 @@ function unregisterShortcuts() {
|
||||
console.log("Shortcuts unregistered");
|
||||
}
|
||||
|
||||
function isValidFileArg(arg) {
|
||||
return (
|
||||
typeof arg === "string" &&
|
||||
!arg.startsWith("-") && // Exclude Electron flags
|
||||
!arg.includes("electron") && // Exclude internal Electron args
|
||||
!arg.endsWith(".app") && // Exclude the app itself on macOS
|
||||
!arg.endsWith("/Contents/MacOS/AppName") // Exclude macOS internal launch paths
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
app.whenReady().then(() => {
|
||||
createWindow();
|
||||
setupMenu();
|
||||
|
Loading…
Reference in New Issue
Block a user