Fix zoom slider with mouse wheel

This commit is contained in:
Juergen Spitzmueller 2021-03-07 15:18:28 +01:00
parent 9aad98836d
commit 128346d03d
2 changed files with 10 additions and 0 deletions

View File

@ -644,6 +644,7 @@ GuiView::GuiView(int id)
statusBar()->addPermanentWidget(zoomslider);
connect(zoomslider, SIGNAL(sliderMoved(int)), this, SLOT(zoomSliderMoved(int)));
connect(zoomslider, SIGNAL(valueChanged(int)), this, SLOT(zoomValueChanged(int)));
connect(this, SIGNAL(currentZoomChanged(int)), zoomslider, SLOT(setValue(int)));
int const iconheight = max(int(d.normalIconSize), fm.height());
@ -756,6 +757,13 @@ void GuiView::zoomSliderMoved(int value)
}
void GuiView::zoomValueChanged(int value)
{
if (value != lyxrc.currentZoom)
zoomSliderMoved(value);
}
QVector<GuiWorkArea*> GuiView::GuiViewPrivate::guiWorkAreas()
{
QVector<GuiWorkArea*> areas;

View File

@ -245,6 +245,8 @@ private Q_SLOTS:
///
void zoomSliderMoved(int);
///
void zoomValueChanged(int);
///
void on_currentWorkAreaChanged(GuiWorkArea *);
///
void onBufferViewChanged();