summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Shaw <andy.shaw@qt.io>2016-11-09 11:59:40 +0100
committerAndy Shaw <andy.shaw@qt.io>2016-11-09 12:15:44 +0000
commit44ac0a336550b45a02cd9b9330d23d7c393b1342 (patch)
tree35cf09cefaf293be91f8bbb12f85f69f5a291ee5
parentc4f6b876d77adca3f9d2640a90a8afcc54bcef9d (diff)
Get the index of all the axes, not just the ones for the first series
Since the count function is operating on all of the axes available to the chart, then the at function needs to be doing the same here. Change-Id: I71ca6c6342d348d4a69956e190a81b4c5b86174f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
-rw-r--r--src/chartsqml2/declarativechart.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/chartsqml2/declarativechart.cpp b/src/chartsqml2/declarativechart.cpp
index 13f01123..86b0d23f 100644
--- a/src/chartsqml2/declarativechart.cpp
+++ b/src/chartsqml2/declarativechart.cpp
@@ -1015,7 +1015,7 @@ QAbstractAxis *DeclarativeChart::axesAtFunc(QQmlListProperty<QAbstractAxis> *lis
{
if (qobject_cast<DeclarativeChart *>(list->object)) {
DeclarativeChart *chart = qobject_cast<DeclarativeChart *>(list->object);
- QList<QAbstractAxis *> axes = chart->m_chart->axes(Qt::Horizontal | Qt::Vertical, chart->m_chart->series()[0]);
+ QList<QAbstractAxis *> axes = chart->m_chart->axes(Qt::Horizontal | Qt::Vertical);
return axes.at(index);
}
return 0;