comparison view/View.cpp @ 1485:0e971e3d93e2 by-id

Tidy; also don't show cancel buttons for alignments
author Chris Cannam
date Wed, 17 Jul 2019 13:12:56 +0100
parents 3943d0720167
children c3cc36c014b8
comparison
equal deleted inserted replaced
1484:b43ff1abdc02 1485:0e971e3d93e2
1745 return; 1745 return;
1746 } 1746 }
1747 1747
1748 QSettings settings; 1748 QSettings settings;
1749 settings.beginGroup("View"); 1749 settings.beginGroup("View");
1750 //!!! perhaps alignments in general should not be cancellable?
1751 bool showCancelButton = settings.value("showcancelbuttons", true).toBool(); 1750 bool showCancelButton = settings.value("showcancelbuttons", true).toBool();
1752 settings.endGroup(); 1751 settings.endGroup();
1753 1752
1754 int ph = height(); 1753 int ph = height();
1755 bool found = false; 1754 bool found = false;
1806 1805
1807 if (wfm || 1806 if (wfm ||
1808 (model && 1807 (model &&
1809 (wfm = ModelById::getAs<RangeSummarisableTimeValueModel> 1808 (wfm = ModelById::getAs<RangeSummarisableTimeValueModel>
1810 (model->getSourceModel())))) { 1809 (model->getSourceModel())))) {
1810
1811 completion = wfm->getAlignmentCompletion(); 1811 completion = wfm->getAlignmentCompletion();
1812
1813 // We don't allow cancelling alignment operations
1814 // - they aren't usually all that expensive, and
1815 // it would leave things in a very uncertain state
1816 showCancelButton = false;
1812 1817
1813 #ifdef DEBUG_PROGRESS_STUFF 1818 #ifdef DEBUG_PROGRESS_STUFF
1814 SVCERR << "View[" << this << "]::checkProgress(" << object << "): " 1819 SVCERR << "View[" << this << "]::checkProgress(" << object << "): "
1815 << "alignment completion = " << completion << endl; 1820 << "alignment completion = " << completion << endl;
1816 #endif 1821 #endif