##// END OF EJS Templates
Bugfix missing xaxis label update on zoomOut
Michal Klocek -
r265:599332cf9659
parent child
Show More
@@ -227,10 +227,13 bool ChartDataSet::previousDomain()
227 void ChartDataSet::setDomain(int index)
227 void ChartDataSet::setDomain(int index)
228 {
228 {
229 QList<QChartAxis*> domainList = m_domainMap.uniqueKeys();
229 QList<QChartAxis*> domainList = m_domainMap.uniqueKeys();
230
231 Domain domain;
232
230 foreach (QChartAxis* axis , domainList) {
233 foreach (QChartAxis* axis , domainList) {
231 int i = m_domainMap.count(axis) - index -1;
234 int i = m_domainMap.count(axis) - index -1;
232 Q_ASSERT(i>=0);
235 Q_ASSERT(i>=0);
233 Domain domain = m_domainMap.values(axis).at(i);
236 domain = m_domainMap.values(axis).at(i);
234 QStringList labels = createLabels(axis,domain.m_minY,domain.m_maxY);
237 QStringList labels = createLabels(axis,domain.m_minY,domain.m_maxY);
235 QList<QChartSeries*> seriesList = m_seriesMap.values(axis);
238 QList<QChartSeries*> seriesList = m_seriesMap.values(axis);
236 foreach(QChartSeries* series, seriesList) {
239 foreach(QChartSeries* series, seriesList) {
@@ -239,7 +242,6 void ChartDataSet::setDomain(int index)
239 emit axisLabelsChanged(axis,labels);
242 emit axisLabelsChanged(axis,labels);
240 }
243 }
241
244
242 Domain domain = m_domainMap.value(axisY());
243 QStringList labels = createLabels(axisX(),domain.m_minX,domain.m_maxX);
245 QStringList labels = createLabels(axisX(),domain.m_minX,domain.m_maxX);
244 emit axisLabelsChanged(axisX(),labels);
246 emit axisLabelsChanged(axisX(),labels);
245 }
247 }
General Comments 0
You need to be logged in to leave comments. Login now