feat(dev/linux): select the wayland backend when reachable in the native desktop app (#2899)

Signed-off-by: omstr <[email protected]>
This commit is contained in:
omster authored and GitHub committed 2026-09-22 21:27:59 +02:00
1 parent 82b2f4ec5e
commit a1e2bf2c8d
3 files changed
+25 -19

No files matched your search

@@ -292,23 +292,6 @@ export function addLinuxHardwareVideoEncodeFeatures(features: Set<string>): void
features.add('AcceleratedVideoEncoder');
}
export interface ChromiumCommandLine {
appendSwitch(name: string, value?: string): void;
getSwitchValue(name: string): string;
hasSwitch(name: string): boolean;
}
export function hasConfiguredOzonePlatformSwitch(commandLine: ChromiumCommandLine = app.commandLine): boolean {
return commandLine.hasSwitch('ozone-platform') || commandLine.getSwitchValue('ozone-platform').length > 0;
}
export function appendLinuxOzonePlatformHint(commandLine: ChromiumCommandLine = app.commandLine): void {
if (process.platform !== 'linux') return;
if (hasConfiguredOzonePlatformSwitch(commandLine)) return;
if (commandLine.hasSwitch('ozone-platform-hint')) return;
commandLine.appendSwitch('ozone-platform-hint', 'auto');
}
export function addWindowsHardwareVideoEncodeFeatures(features: Set<string>): void {
if (process.platform !== 'win32') return;
features.add('WebRtcAV1HWEncode');
-2
View File
@@ -25,7 +25,6 @@ import {
appendEnabledBlinkFeature,
appendEnabledChromiumFeatures,
appendLinuxChromiumFlagsConfig,
appendLinuxOzonePlatformHint,
appendWindowsGpuDriverWorkaroundSwitches,
BASE_DISABLED_CHROMIUM_FEATURES,
MIDDLE_CLICK_AUTOSCROLL_BLINK_FEATURE,
@@ -271,7 +270,6 @@ if (launchConfigurationError) {
if (launchDiagnosticOptions.safeMode !== true) {
appendLinuxChromiumFlagsConfig(userDataConfig.channel);
}
appendLinuxOzonePlatformHint();
if (process.platform === 'win32') {
app.setToastActivatorCLSID(WINDOWS_TOAST_ACTIVATOR_CLSID);
app.setAppUserModelId(WINDOWS_APP_USER_MODEL_ID);