moved isWayland to constants
This commit is contained in:
parent
dd6bd74427
commit
d37f07cedb
3 changed files with 5 additions and 4 deletions
|
@ -61,3 +61,6 @@ export const enum MessageBoxChoice {
|
|||
Default,
|
||||
Cancel
|
||||
}
|
||||
|
||||
export const isWayland =
|
||||
process.platform === "linux" && (process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY);
|
||||
|
|
|
@ -31,13 +31,13 @@ import {
|
|||
DATA_DIR,
|
||||
DEFAULT_HEIGHT,
|
||||
DEFAULT_WIDTH,
|
||||
isWayland,
|
||||
MessageBoxChoice,
|
||||
MIN_HEIGHT,
|
||||
MIN_WIDTH,
|
||||
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";
|
||||
|
|
|
@ -8,11 +8,9 @@ import { desktopCapturer, session, Streams } from "electron";
|
|||
import type { StreamPick } from "renderer/components/ScreenSharePicker";
|
||||
import { IpcEvents } from "shared/IpcEvents";
|
||||
|
||||
import { isWayland } from "./constants";
|
||||
import { handle } from "./utils/ipcWrappers";
|
||||
|
||||
export const isWayland =
|
||||
process.platform === "linux" && (process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY);
|
||||
|
||||
export function registerScreenShareHandler() {
|
||||
handle(IpcEvents.CAPTURER_GET_LARGE_THUMBNAIL, async (_, id: string) => {
|
||||
const sources = await desktopCapturer.getSources({
|
||||
|
|
Loading…
Reference in a new issue