Skip to content

Commit

Permalink
fix: ensure the maximize/minimize-frame command are executed in sdl2 …
Browse files Browse the repository at this point in the history
…main thread.
  • Loading branch information
sakurawald authored Nov 20, 2024
1 parent 2fa16b8 commit 6daba4c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions frontends/sdl2/frame.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@

(define-command maximize-frame () ()
"Maximize the frame."
(sdl2:maximize-window (lem-sdl2/display::display-window (lem-sdl2/display:current-display))))
(sdl2:in-main-thread ()
(sdl2:maximize-window (lem-sdl2/display::display-window (lem-sdl2/display:current-display)))))

(define-command minimize-frame () ()
"Minimize the frame."
(sdl2:minimize-window (lem-sdl2/display::display-window (lem-sdl2/display:current-display))))
(sdl2:in-main-thread ()
(sdl2:minimize-window (lem-sdl2/display::display-window (lem-sdl2/display:current-display)))))

0 comments on commit 6daba4c

Please sign in to comment.