comparison framework/MainWindowBase.cpp @ 183:da514e36839a

* If, when a model is removed from a layer, it is found that the only remaining layers representing that model are ruler layers, then stop playing the model (probable fix to bug reported by Tim Crawford)
author Chris Cannam
date Wed, 23 Sep 2009 11:19:43 +0000
parents 84b2c1a4984a
children f701c0c686e5
comparison
equal deleted inserted replaced
182:58b64dbb49c6 183:da514e36839a
2644 for (int i = 0; i < m_paneStack->getPaneCount(); ++i) { 2644 for (int i = 0; i < m_paneStack->getPaneCount(); ++i) {
2645 Pane *pane = m_paneStack->getPane(i); 2645 Pane *pane = m_paneStack->getPane(i);
2646 if (!pane) continue; 2646 if (!pane) continue;
2647 for (int j = 0; j < pane->getLayerCount(); ++j) { 2647 for (int j = 0; j < pane->getLayerCount(); ++j) {
2648 Layer *pl = pane->getLayer(j); 2648 Layer *pl = pane->getLayer(j);
2649 if (pl && (pl->getModel() == model)) { 2649 if (pl &&
2650 !dynamic_cast<TimeRulerLayer *>(pl) &&
2651 (pl->getModel() == model)) {
2650 found = true; 2652 found = true;
2651 break; 2653 break;
2652 } 2654 }
2653 } 2655 }
2654 if (found) break; 2656 if (found) break;