mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
(#617) Improved wheel zoom on curves
The scroll bar was updated as part of the wheel zoom event, and a signal from this update caused a panning of the curve
This commit is contained in:
parent
dac0db0fb9
commit
8047b9e92e
@ -199,11 +199,15 @@ void RiuWellLogPlot::updateScrollBar(double minDepth, double maxDepth)
|
||||
|
||||
double visibleDepth = maxDepth - minDepth;
|
||||
|
||||
m_scrollBar->setRange((int) availableMinDepth, (int) (ceil(availableMaxDepth - visibleDepth)));
|
||||
m_scrollBar->setPageStep((int) visibleDepth);
|
||||
m_scrollBar->setValue((int) minDepth);
|
||||
m_scrollBar->blockSignals(true);
|
||||
{
|
||||
m_scrollBar->setRange((int) availableMinDepth, (int) (ceil(availableMaxDepth - visibleDepth)));
|
||||
m_scrollBar->setPageStep((int) visibleDepth);
|
||||
m_scrollBar->setValue((int) minDepth);
|
||||
|
||||
m_scrollBar->setVisible(true);
|
||||
m_scrollBar->setVisible(true);
|
||||
}
|
||||
m_scrollBar->blockSignals(false);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user