Skip to content

Commit

Permalink
Workround for 3D rendering on some Linux systems
Browse files Browse the repository at this point in the history
  • Loading branch information
Scavanger committed Dec 18, 2024
1 parent 7801390 commit 2b7ec14
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions js/main/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@ let selectBluetoothCallback = null;

const store = new Store();

// Workaround for some Linux systems: https://github.com/electron/electron/issues/32760
if (process.platform === 'linux') {
app.disableHardwareAcceleration();
}

// In Electron the bluetooth device chooser didn't exist, so we have to build our own
function createDeviceChooser() {
bluetoothDeviceChooser = new BrowserWindow({
Expand Down Expand Up @@ -180,7 +185,7 @@ function createWindow() {
}
});

app.commandLine.appendSwitch('disable-features', 'OutOfBlinkCors')
app.commandLine.appendSwitch('disable-features', 'OutOfBlinkCors');

if (process.platform === "linux"){
app.commandLine.appendSwitch("enable-experimental-web-platform-features", true);
Expand Down Expand Up @@ -210,7 +215,7 @@ function createWindow() {
app.on('before-quit', async () => {
await tcp.close();
await serial.close();
child_process.stopAll();
child_process.stop();
});

app.on('window-all-closed', async () => {
Expand Down

0 comments on commit 2b7ec14

Please sign in to comment.