Mercurial > hg > svgui
diff view/Pane.cpp @ 272:87e4c880b4c8
* highlight the nearest measurement rect
* fix rewind during playback
author | Chris Cannam |
---|---|
date | Fri, 29 Jun 2007 13:58:08 +0000 |
parents | 61a704654497 |
children | b9380f679f70 |
line wrap: on
line diff
--- a/view/Pane.cpp Thu Jun 28 14:50:58 2007 +0000 +++ b/view/Pane.cpp Fri Jun 29 13:58:08 2007 +0000 @@ -454,7 +454,9 @@ } if (toolMode == ViewManager::MeasureMode && topLayer) { - topLayer->paintMeasurementRects(this, paint); + bool showFocus = false; + if (!m_manager || !m_manager->isPlaying()) showFocus = true; + topLayer->paintMeasurementRects(this, paint, showFocus, m_identifyPoint); } if (selectionIsBeingEdited()) { @@ -1213,6 +1215,8 @@ if (!m_manager->isPlaying()) { + bool updating = false; + if (getSelectedLayer()) { bool previouslyIdentifying = m_identifyFeatures; @@ -1221,6 +1225,17 @@ if (m_identifyFeatures != previouslyIdentifying || m_identifyPoint != prevPoint) { update(); + updating = true; + } + } + + if (!updating && mode == ViewManager::MeasureMode && + m_manager && !m_manager->isPlaying()) { + + Layer *layer = getTopLayer(); + if (layer && layer->nearestMeasurementRectChanged + (this, prevPoint, m_identifyPoint)) { + update(); } } }