Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/boomer.nim
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,15 @@ import la
import strutils
import math
import options
import system

type Shader = tuple[path, content: string]

proc check_x11() =
if getEnv("XDG_SESSION_TYPE") != "x11":
echo "ERROR: Boomer doesn't work on Wayland..."
system.quit(1)

proc readShader(file: string): Shader =
when nimvm:
result.path = file
Expand Down Expand Up @@ -180,6 +186,8 @@ proc main() =
var windowed = false
var delaySec = 0.0

check_x11()

# TODO(#95): Make boomer optionally wait for some kind of event (for example, key press)
block:
proc versionQuit() =
Expand Down