mirror of
https://github.com/fulpstation/fulpstation.git
synced 2025-12-09 16:09:15 +00:00
Fix wonky window dragging when using fancy tgui in some special cases (#46111)
This pull request fixes the Issue #44038, where TGUI windows get stuck at the bottom of the screen in this very special case: Windows 10 taskbar is not located at the bottom of the screen (in my case, taskbar was on top); Fancy UI is enabled. This is because BYOND uses and reports only the "usable" screen resolution instead of an actual physical resolution [citation needed], and therefore window coordinate space is offset by 40px or more (a size of a Windows 10 taskbar), which causes that rapid uncontrolled propulsion of TGUI windows away from the taskbar. I also took the liberty to refactor some of the code in 'util/byond' to my liking and adding a few helper methods, including runCommand(command) and callByond(url, params) -> Promise. Promise-based interface is a first step to start using async/await and making more dynamic calls in tgui. Why It's Good For The Game Window dragging is now more robust with the (currently default) fancy TGUI. Code accounts for the screen space offset between BYOND and the in-game browser. Changelog cl fix: fixed wonky window dragging when using fancy tgui in some special cases /cl
This commit is contained in:
@@ -9,3 +9,7 @@ indent_size = 2
|
||||
|
||||
[*.py]
|
||||
indent_style = space
|
||||
|
||||
[/tgui/**/*.{js,styl,ract,json,html}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
Reference in New Issue
Block a user