diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2023-07-10 15:50:47 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2023-07-10 15:50:47 -0700 |
commit | e68261d7a346d45eab4c0d606b5c5010823badd7 (patch) | |
tree | 51c96a30c5b0460b9d51141dd7808669b7b7b329 | |
parent | 9df1c3f997e04194edc16db4999d204ea46332ff (diff) | |
download | lines.love-e68261d7a346d45eab4c0d606b5c5010823badd7.tar.gz |
bugfix: preserve window position
-rw-r--r-- | source.lua | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/source.lua b/source.lua index b4489e1..9326152 100644 --- a/source.lua +++ b/source.lua @@ -164,8 +164,13 @@ function source.resize_window_from_settings(settings) end function source.set_window_position_from_settings(settings) - -- love.window.setPosition doesn't quite seem to do what is asked of it on Linux. - App.screen.move(settings.x, settings.y-37, settings.displayindex) + local os = love.system.getOS() + if os == 'Linux' then + -- love.window.setPosition doesn't quite seem to do what is asked of it on Linux. + App.screen.move(settings.x, settings.y-37, settings.displayindex) + else + App.screen.move(settings.x, settings.y, settings.displayindex) + end end function source.initialize_default_settings() |