# HG changeset patch # User sam # Date 1703668476 -25200 # Node ID 0f87e84d57fdede5dc7162de1a8e75c176bfb17b # Parent 7c31e5a780f151eba1760f2eb666c6414847f361 fix: do not try to change fullscreen if already in correct status diff -r 7c31e5a780f1 -r 0f87e84d57fd semicongine/engine.nim --- a/semicongine/engine.nim Wed Dec 27 16:08:13 2023 +0700 +++ b/semicongine/engine.nim Wed Dec 27 16:14:36 2023 +0700 @@ -210,5 +210,6 @@ func hideSystemCursor*(engine: Engine) = engine.window.hideSystemCursor() func fullscreen*(engine: Engine): bool = engine.fullscreen proc `fullscreen=`*(engine: var Engine, enable: bool) = - engine.fullscreen = enable - engine.window.fullscreen(engine.fullscreen) + if enable != engine.fullscreen: + engine.fullscreen = enable + engine.window.fullscreen(engine.fullscreen)