mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-25 05:04:07 +01:00
Add: Vehicle window zoom with mouse wheel
This commit is contained in:
committed by
rubidium42
parent
c3a051a213
commit
72276e2d3c
@@ -3317,6 +3317,13 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void OnMouseWheel(int wheel) override
|
||||
{
|
||||
if (_settings_client.gui.scrollwheel_scrolling != SWS_OFF) {
|
||||
DoZoomInOutWindow(wheel < 0 ? ZOOM_IN : ZOOM_OUT, this, false);
|
||||
}
|
||||
}
|
||||
|
||||
void OnResize() override
|
||||
{
|
||||
if (this->viewport != nullptr) {
|
||||
|
||||
Reference in New Issue
Block a user