From 8ec4765a5bb8f999495dfab1ffb648a83b9ed886 Mon Sep 17 00:00:00 2001 From: Observer KRypt0n_ Date: Sat, 8 Jan 2022 17:11:13 +0200 Subject: [PATCH] Fixed windows sizing on wayland --- src/sass/basic.sass | 6 ------ src/sass/index.sass | 6 ++++++ src/settings.svelte | 1 + src/splash.svelte | 1 + src/ts/launcher/State.ts | 2 ++ 5 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/sass/basic.sass b/src/sass/basic.sass index 65bb74e..8c4c415 100644 --- a/src/sass/basic.sass +++ b/src/sass/basic.sass @@ -8,12 +8,6 @@ body -webkit-user-select: none cursor: default -img.background - position: absolute - - width: 100% - height: 100% - ::-webkit-scrollbar width: 10px diff --git a/src/sass/index.sass b/src/sass/index.sass index 8c1f4c9..a266417 100644 --- a/src/sass/index.sass +++ b/src/sass/index.sass @@ -1,5 +1,11 @@ @import "basic" +img.background + position: absolute + + width: 100% + height: 100% + #info position: absolute diff --git a/src/settings.svelte b/src/settings.svelte index fe0e49c..7c650ac 100644 --- a/src/settings.svelte +++ b/src/settings.svelte @@ -174,6 +174,7 @@ // Do some stuff when all the content will be loaded onMount(() => { Window.current.show(); + Window.current.setSize({ width: 900, height: 600 }); Window.current.center(900, 600); }); diff --git a/src/splash.svelte b/src/splash.svelte index b5025bb..515cc14 100644 --- a/src/splash.svelte +++ b/src/splash.svelte @@ -20,6 +20,7 @@ onMount(() => { Window.current.show(); + Window.current.setSize({ width: 300, height: 400 }); Window.current.center(300, 400); }); diff --git a/src/ts/launcher/State.ts b/src/ts/launcher/State.ts index 191e480..162d0b6 100644 --- a/src/ts/launcher/State.ts +++ b/src/ts/launcher/State.ts @@ -87,6 +87,8 @@ export default class State IPC.write('launcher-loaded'); Window.current.show(); + Window.current.setSize({ width: 1280, height: 700 }); + Window.current.center(1280, 700); }); }