Various GUI improvements #19
|
@ -112,11 +112,11 @@ export component MainTab inherits Rectangle {
|
|||
|
||||
function update_viewport() {
|
||||
if abs(self.viewport-x) + self.width > self.viewport-width {
|
||||
self.viewport-x = 0;
|
||||
self.viewport-x += (self.width + abs(self.viewport-x)) - self.viewport-width;
|
||||
}
|
||||
|
||||
if abs(self.viewport-y) + self.height > self.viewport-height {
|
||||
self.viewport-y = 0;
|
||||
self.viewport-y += (self.height + abs(self.viewport-y)) - self.viewport-height;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue