Преглед на файлове

fix(electron): 移除disableHardwareAcceleration和disableGpu标志,避免首次加载慢

ethanfly преди 3 дни
родител
ревизия
5a8f40462a
променени са 1 файла, в които са добавени 0 реда и са изтрити 5 реда
  1. 0 5
      client/electron/main.ts

+ 0 - 5
client/electron/main.ts

@@ -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');