1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-01-11 18:24:43 +02:00

Desktop: Fixes #9130: Allow Electron --disable-gpu flag (#9179)

This commit is contained in:
Roman Orlowski 2023-11-07 14:58:39 +03:00 committed by GitHub
parent 88b44a0f74
commit b030ca914d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,5 +1,3 @@
import Logger, { LogLevel } from '@joplin/utils/Logger';
import JoplinError from '../JoplinError';
import { _ } from '../locale';
@ -152,6 +150,13 @@ const processStartFlags = async (argv: string[], setDefaults = true) => {
continue;
}
if (arg === '--disable-gpu') {
// Electron-specific flag - ignore it
// Allows users to disable GPU acceleration
argv.splice(0, 1);
continue;
}
if (arg.length && arg[0] === '-') {
throw new JoplinError(_('Unknown flag: %s', arg), 'flagError');
} else {