# HG changeset patch # User Chris Cannam # Date 1172499501 0 # Node ID 942cfa1df9664db7d6b283931e44235fd219ee17 # Parent 258af0c4dc289395f39abd478a2694706b8587e1 * Fix occasional misplacement of zoom wheels * Disable tearoff in context menu (it always got activated when you just clicked and released) diff -r 258af0c4dc28 -r 942cfa1df966 view/Pane.cpp --- a/view/Pane.cpp Wed Feb 14 17:52:06 2007 +0000 +++ b/view/Pane.cpp Mon Feb 26 14:18:21 2007 +0000 @@ -202,12 +202,15 @@ // std::cerr << "set default value to " << m_hthumb->getDefaultValue() << std::endl; } + bool haveVThumb = false; + if (layer) { int defaultStep = 0; int max = layer->getVerticalZoomSteps(defaultStep); if (max == 0) { m_vthumb->hide(); } else { + haveVThumb = true; m_vthumb->show(); m_vthumb->blockSignals(true); m_vthumb->setMinimumValue(0); @@ -232,10 +235,14 @@ connect(m_manager, SIGNAL(zoomLevelChanged()), this, SLOT(zoomLevelChanged())); } - if (m_vthumb->isVisible()) { + if (haveVThumb) { + std::cerr << "vthumb is visible, moving to " << height() -86 << std::endl; + m_headsUpDisplay->setFixedHeight(m_vthumb->height() + m_hthumb->height()); m_headsUpDisplay->move(width() - 86, height() - 86); } else { - m_headsUpDisplay->move(width() - 86, height() - 51); + std::cerr << "vthumb is invisible, moving to " << height() -51 << std::endl; + m_headsUpDisplay->setFixedHeight(m_hthumb->height()); + m_headsUpDisplay->move(width() - 86, height() - 16); } } else { m_headsUpDisplay->hide();