Merge remote-tracking branch 'upstream/master'
This commit is contained in:
@@ -57,7 +57,7 @@ public:
|
||||
this->InitNested(window_number);
|
||||
|
||||
NWidgetViewport *nvp = this->GetWidget<NWidgetViewport>(WID_EV_VIEWPORT);
|
||||
nvp->InitializeViewport(this, tile, ScaleZoomGUI(ZOOM_LVL_VIEWPORT));
|
||||
nvp->InitializeViewport(this, tile, ScaleZoomGUI(ZoomLevel::Viewport));
|
||||
if (_settings_client.gui.zoom_min == viewport->zoom) this->DisableWidget(WID_EV_ZOOM_IN);
|
||||
}
|
||||
|
||||
@@ -124,8 +124,9 @@ public:
|
||||
return widget == WID_EV_VIEWPORT;
|
||||
}
|
||||
|
||||
void OnMouseWheel(int wheel) override
|
||||
void OnMouseWheel(int wheel, WidgetID widget) override
|
||||
{
|
||||
if (widget != WID_EV_VIEWPORT) return;
|
||||
if (_settings_client.gui.scrollwheel_scrolling != SWS_OFF) {
|
||||
ZoomInOrOutToCursorWindow(wheel < 0, this);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user