mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-13 09:26:11 -04:00
gui: fix odd window size workaround
This commit is contained in:
parent
935a46f99b
commit
c512548be1
@ -134,16 +134,10 @@ class GUIRenderer(
|
|||||||
val output = Vec2i(this)
|
val output = Vec2i(this)
|
||||||
// ToDo: This is just a dirty workaround and does not fix the problem at all
|
// ToDo: This is just a dirty workaround and does not fix the problem at all
|
||||||
while (output.x % scale.toInt() != 0) {
|
while (output.x % scale.toInt() != 0) {
|
||||||
output.x--
|
output.x++
|
||||||
if (output.x < 0) {
|
|
||||||
output.x = 0
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
while (output.y % scale.toInt() != 0) {
|
while (output.y % scale.toInt() != 0) {
|
||||||
output.y--
|
output.y++
|
||||||
if (output.y < 0) {
|
|
||||||
output.y = 0
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return output / scale
|
return output / scale
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user