|
|
@@ -306,13 +306,8 @@ if (!gotTheLock) {
|
|
|
});
|
|
|
|
|
|
// ========== 降低 Electron 内存占用(必须在 app.whenReady 之前) ==========
|
|
|
- app.disableHardwareAcceleration();
|
|
|
app.commandLine.appendSwitch('js-flags', '--max-old-space-size=512');
|
|
|
- app.commandLine.appendSwitch('disable-gpu');
|
|
|
- app.commandLine.appendSwitch('disable-software-rasterizer');
|
|
|
app.commandLine.appendSwitch('renderer-process-limit', '2');
|
|
|
- app.commandLine.appendSwitch('disable-backgrounding-occluded-windows');
|
|
|
- app.commandLine.appendSwitch('disable-renderer-backgrounding');
|
|
|
|
|
|
app.whenReady().then(async () => {
|
|
|
logMemory('AppReady');
|