Use SquirrelMacEnableDirectContentsWrite on macOS
This commit is contained in:
parent
dba2a6b166
commit
e8ed8b3400
1 changed files with 13 additions and 1 deletions
14
app/main.ts
14
app/main.ts
|
@ -94,7 +94,7 @@ import type { MenuActionType } from '../ts/types/menu';
|
||||||
import { createTemplate } from './menu';
|
import { createTemplate } from './menu';
|
||||||
import { installFileHandler, installWebHandler } from './protocol_filter';
|
import { installFileHandler, installWebHandler } from './protocol_filter';
|
||||||
import * as OS from '../ts/OS';
|
import * as OS from '../ts/OS';
|
||||||
import { isProduction } from '../ts/util/version';
|
import { isBeta, isProduction } from '../ts/util/version';
|
||||||
import {
|
import {
|
||||||
isSgnlHref,
|
isSgnlHref,
|
||||||
isCaptchaHref,
|
isCaptchaHref,
|
||||||
|
@ -120,6 +120,18 @@ import type { LoggerType } from '../ts/types/Logging';
|
||||||
|
|
||||||
const animationSettings = systemPreferences.getAnimationSettings();
|
const animationSettings = systemPreferences.getAnimationSettings();
|
||||||
|
|
||||||
|
if (
|
||||||
|
OS.isMacOS() &&
|
||||||
|
!isProduction(app.getVersion()) &&
|
||||||
|
!isBeta(app.getVersion())
|
||||||
|
) {
|
||||||
|
systemPreferences.setUserDefault(
|
||||||
|
'SquirrelMacEnableDirectContentsWrite',
|
||||||
|
'boolean',
|
||||||
|
true
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
// Keep a global reference of the window object, if you don't, the window will
|
// Keep a global reference of the window object, if you don't, the window will
|
||||||
// be closed automatically when the JavaScript object is garbage collected.
|
// be closed automatically when the JavaScript object is garbage collected.
|
||||||
let mainWindow: BrowserWindow | undefined;
|
let mainWindow: BrowserWindow | undefined;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue