mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 18:12:29 +08:00
fix(electron): crash on some Linux distributions
This commit is contained in:
parent
3046fe2bf2
commit
1a2bb1e407
@ -22,6 +22,12 @@ async function main() {
|
|||||||
electron.app.commandLine.appendSwitch("enable-experimental-web-platform-features");
|
electron.app.commandLine.appendSwitch("enable-experimental-web-platform-features");
|
||||||
electron.app.commandLine.appendSwitch("lang", options.getOptionOrNull("formattingLocale") ?? "en");
|
electron.app.commandLine.appendSwitch("lang", options.getOptionOrNull("formattingLocale") ?? "en");
|
||||||
|
|
||||||
|
// Electron 36 crashes with "Using GTK 2/3 and GTK 4 in the same process is not supported" on some distributions.
|
||||||
|
// See https://github.com/electron/electron/issues/46538 for more info.
|
||||||
|
if (process.platform === "linux") {
|
||||||
|
electron.app.commandLine.appendSwitch("gtk-version", "3");
|
||||||
|
}
|
||||||
|
|
||||||
// Quit when all windows are closed, except on macOS. There, it's common
|
// Quit when all windows are closed, except on macOS. There, it's common
|
||||||
// for applications and their menu bar to stay active until the user quits
|
// for applications and their menu bar to stay active until the user quits
|
||||||
// explicitly with Cmd + Q.
|
// explicitly with Cmd + Q.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user