use keybinds only on wayland

This commit is contained in:
Oleh Polisan 2024-05-24 17:13:05 +03:00
parent a3eea96bb1
commit dd6bd74427
2 changed files with 3 additions and 2 deletions

View file

@ -37,6 +37,7 @@ import {
VENCORD_FILES_DIR
} from "./constants";
import { initKeybinds } from "./keybinds";
import { isWayland } from "./screenShare";
import { Settings, State, VencordSettings } from "./settings";
import { createSplashWindow } from "./splash";
import { makeLinksOpenExternally } from "./utils/makeLinksOpenExternally";
@ -499,5 +500,5 @@ export async function createWindows() {
});
initArRPC();
initKeybinds();
if (isWayland) initKeybinds();
}

View file

@ -10,7 +10,7 @@ import { IpcEvents } from "shared/IpcEvents";
import { handle } from "./utils/ipcWrappers";
const isWayland =
export const isWayland =
process.platform === "linux" && (process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY);
export function registerScreenShareHandler() {