From e08865d3185f501c20a3edd28c3ee80cf5a27c04 2012-03-29 10:13:42 From: Michal Klocek Date: 2012-03-29 10:13:42 Subject: [PATCH] Adds owvership to domain --- diff --git a/src/chartdataset.cpp b/src/chartdataset.cpp index 53a3de7..c8a029d 100644 --- a/src/chartdataset.cpp +++ b/src/chartdataset.cpp @@ -66,7 +66,7 @@ void ChartDataSet::addSeries(QSeries* series, QChartAxis *axisY) Domain* domain = m_axisDomainMap.value(axisY); if(!domain) { - domain = new Domain(); + domain = new Domain(axisY); QObject::connect(axisY,SIGNAL(changed(qreal,qreal,int,bool)),domain,SLOT(handleAxisYChanged(qreal,qreal,int,bool))); QObject::connect(axisX(),SIGNAL(changed(qreal,qreal,int,bool)),domain,SLOT(handleAxisXChanged(qreal,qreal,int,bool))); QObject::connect(domain,SIGNAL(rangeYChanged(qreal,qreal,int)),axisY,SLOT(handleAxisRangeChanged(qreal,qreal,int)));