##// END OF EJS Templates
normalize signal/slot signatures
Jani Honkonen -
r2110:a93a773ef512
parent child
Show More
@@ -58,12 +58,12 int main(int argc, char *argv[])
58 foreach (QString month, months)
58 foreach (QString month, months)
59 *series << new DrilldownSlice(qrand() % 1000, month, yearSeries);
59 *series << new DrilldownSlice(qrand() % 1000, month, yearSeries);
60
60
61 QObject::connect(series, SIGNAL(clicked(QPieSlice *)), chart, SLOT(handleSliceClicked(QPieSlice *)));
61 QObject::connect(series, SIGNAL(clicked(QPieSlice*)), chart, SLOT(handleSliceClicked(QPieSlice*)));
62
62
63 *yearSeries << new DrilldownSlice(series->sum(), name, series);
63 *yearSeries << new DrilldownSlice(series->sum(), name, series);
64 }
64 }
65
65
66 QObject::connect(yearSeries, SIGNAL(clicked(QPieSlice *)), chart, SLOT(handleSliceClicked(QPieSlice *)));
66 QObject::connect(yearSeries, SIGNAL(clicked(QPieSlice*)), chart, SLOT(handleSliceClicked(QPieSlice*)));
67
67
68 chart->changeSeries(yearSeries);
68 chart->changeSeries(yearSeries);
69
69
@@ -68,11 +68,11 int main(int argc, char *argv[])
68 }
68 }
69
69
70 // Use clicked signal to implement drilldown
70 // Use clicked signal to implement drilldown
71 QObject::connect(weeklySeries, SIGNAL(clicked(int, QBarSet *)), drilldownChart, SLOT(handleClicked(int, QBarSet *)));
71 QObject::connect(weeklySeries, SIGNAL(clicked(int,QBarSet*)), drilldownChart, SLOT(handleClicked(int,QBarSet*)));
72 }
72 }
73
73
74 // Enable drilldown from season series using clicked signal
74 // Enable drilldown from season series using clicked signal
75 QObject::connect(seasonSeries, SIGNAL(clicked(int, QBarSet *)), drilldownChart, SLOT(handleClicked(int, QBarSet *)));
75 QObject::connect(seasonSeries, SIGNAL(clicked(int,QBarSet*)), drilldownChart, SLOT(handleClicked(int,QBarSet*)));
76 //! [3]
76 //! [3]
77
77
78 //! [4]
78 //! [4]
@@ -253,12 +253,12 DeclarativeChart::DeclarativeChart(QDeclarativeItem *parent)
253 m_margins->setLeft(m_chart->margins().left());
253 m_margins->setLeft(m_chart->margins().left());
254 m_margins->setRight(m_chart->margins().right());
254 m_margins->setRight(m_chart->margins().right());
255 m_margins->setBottom(m_chart->margins().bottom());
255 m_margins->setBottom(m_chart->margins().bottom());
256 connect(m_margins, SIGNAL(topChanged(int, int, int, int)), this, SLOT(changeMinimumMargins(int, int, int, int)));
256 connect(m_margins, SIGNAL(topChanged(int,int,int,int)), this, SLOT(changeMinimumMargins(int,int,int,int)));
257 connect(m_margins, SIGNAL(bottomChanged(int, int, int, int)), this, SLOT(changeMinimumMargins(int, int, int, int)));
257 connect(m_margins, SIGNAL(bottomChanged(int,int,int,int)), this, SLOT(changeMinimumMargins(int,int,int,int)));
258 connect(m_margins, SIGNAL(leftChanged(int, int, int, int)), this, SLOT(changeMinimumMargins(int, int, int, int)));
258 connect(m_margins, SIGNAL(leftChanged(int,int,int,int)), this, SLOT(changeMinimumMargins(int,int,int,int)));
259 connect(m_margins, SIGNAL(rightChanged(int, int, int, int)), this, SLOT(changeMinimumMargins(int, int, int, int)));
259 connect(m_margins, SIGNAL(rightChanged(int,int,int,int)), this, SLOT(changeMinimumMargins(int,int,int,int)));
260 connect(m_chart->d_ptr->m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)), this, SLOT(handleSeriesAdded(QAbstractSeries *, Domain *)));
260 connect(m_chart->d_ptr->m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)), this, SLOT(handleSeriesAdded(QAbstractSeries*,Domain*)));
261 connect(m_chart->d_ptr->m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)), this, SIGNAL(seriesRemoved(QAbstractSeries *)));
261 connect(m_chart->d_ptr->m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)), this, SIGNAL(seriesRemoved(QAbstractSeries*)));
262 }
262 }
263
263
264 void DeclarativeChart::handleSeriesAdded(QAbstractSeries *series, Domain *domain)
264 void DeclarativeChart::handleSeriesAdded(QAbstractSeries *series, Domain *domain)
@@ -144,10 +144,10 void AbstractBarChartItem::handleDataStructureChanged()
144 // Bars
144 // Bars
145 Bar *bar = new Bar(set, c, this);
145 Bar *bar = new Bar(set, c, this);
146 m_bars.append(bar);
146 m_bars.append(bar);
147 connect(bar, SIGNAL(clicked(int, QBarSet*)), m_series, SIGNAL(clicked(int, QBarSet*)));
147 connect(bar, SIGNAL(clicked(int,QBarSet*)), m_series, SIGNAL(clicked(int,QBarSet*)));
148 connect(bar, SIGNAL(hovered(bool, QBarSet*)), m_series, SIGNAL(hovered(bool, QBarSet*)));
148 connect(bar, SIGNAL(hovered(bool,QBarSet*)), m_series, SIGNAL(hovered(bool,QBarSet*)));
149 connect(bar, SIGNAL(clicked(int, QBarSet*)), set, SIGNAL(clicked(int)));
149 connect(bar, SIGNAL(clicked(int,QBarSet*)), set, SIGNAL(clicked(int)));
150 connect(bar, SIGNAL(hovered(bool, QBarSet*)), set, SIGNAL(hovered(bool)));
150 connect(bar, SIGNAL(hovered(bool,QBarSet*)), set, SIGNAL(hovered(bool)));
151 m_layout.append(QRectF(0, 0, 0, 0));
151 m_layout.append(QRectF(0, 0, 0, 0));
152
152
153 // Labels
153 // Labels
@@ -179,10 +179,10 void tst_ChartDataSet::addSeries()
179
179
180 QFETCH(QAbstractSeries*, series);
180 QFETCH(QAbstractSeries*, series);
181
181
182 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*, Domain *)));
182 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
183 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
183 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
184 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)));
184 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
185 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
185 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
186
186
187 m_dataset->addSeries(series);
187 m_dataset->addSeries(series);
188 m_dataset->createDefaultAxes();
188 m_dataset->createDefaultAxes();
@@ -236,10 +236,10 void tst_ChartDataSet::setAxisX()
236
236
237 Q_ASSERT(seriesList.count() == axisList.count());
237 Q_ASSERT(seriesList.count() == axisList.count());
238
238
239 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis *,Domain*)));
239 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
240 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis *)));
240 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
241 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *,Domain*)));
241 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
242 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
242 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
243
243
244 foreach (QAbstractSeries* series, seriesList){
244 foreach (QAbstractSeries* series, seriesList){
245 m_dataset->addSeries(series);
245 m_dataset->addSeries(series);
@@ -252,8 +252,8 void tst_ChartDataSet::setAxisX()
252
252
253 QSignalSpy spy4(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
253 QSignalSpy spy4(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
254 QSignalSpy spy5(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
254 QSignalSpy spy5(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
255 QSignalSpy spy6(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *,Domain*)));
255 QSignalSpy spy6(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
256 QSignalSpy spy7(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
256 QSignalSpy spy7(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
257
257
258 for(int i=0 ; i < seriesList.count(); i++){
258 for(int i=0 ; i < seriesList.count(); i++){
259 m_dataset->setAxis(seriesList.at(i),axisList.at(i),Qt::Horizontal);
259 m_dataset->setAxis(seriesList.at(i),axisList.at(i),Qt::Horizontal);
@@ -284,8 +284,8 void tst_ChartDataSet::setAxisY()
284
284
285 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
285 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
286 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
286 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
287 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *,Domain*)));
287 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
288 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
288 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
289
289
290 foreach (QAbstractSeries* series, seriesList){
290 foreach (QAbstractSeries* series, seriesList){
291 m_dataset->addSeries(series);
291 m_dataset->addSeries(series);
@@ -298,8 +298,8 void tst_ChartDataSet::setAxisY()
298
298
299 QSignalSpy spy4(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
299 QSignalSpy spy4(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
300 QSignalSpy spy5(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
300 QSignalSpy spy5(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
301 QSignalSpy spy6(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *,Domain*)));
301 QSignalSpy spy6(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
302 QSignalSpy spy7(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
302 QSignalSpy spy7(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
303
303
304 for(int i=0 ; i < seriesList.count(); i++){
304 for(int i=0 ; i < seriesList.count(); i++){
305 m_dataset->setAxis(seriesList.at(i),axisList.at(i),Qt::Vertical);
305 m_dataset->setAxis(seriesList.at(i),axisList.at(i),Qt::Vertical);
@@ -327,10 +327,10 void tst_ChartDataSet::removeSeries()
327 m_dataset->addSeries(series);
327 m_dataset->addSeries(series);
328 m_dataset->createDefaultAxes();
328 m_dataset->createDefaultAxes();
329
329
330 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*, Domain *)));
330 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
331 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
331 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
332 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)));
332 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
333 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
333 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
334
334
335 m_dataset->removeSeries(series);
335 m_dataset->removeSeries(series);
336
336
@@ -373,10 +373,10 void tst_ChartDataSet::removeAllSeries()
373 m_dataset->setAxis(seriesList.at(i), axisList.at(i),Qt::Horizontal);
373 m_dataset->setAxis(seriesList.at(i), axisList.at(i),Qt::Horizontal);
374 }
374 }
375
375
376 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis *, Domain *)));
376 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
377 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis *)));
377 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
378 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)));
378 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
379 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
379 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
380
380
381 m_dataset->removeAllSeries();
381 m_dataset->removeAllSeries();
382
382
@@ -405,10 +405,10 void tst_ChartDataSet::seriesCount()
405 m_dataset->addSeries(series);
405 m_dataset->addSeries(series);
406 }
406 }
407
407
408 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis *, Domain *)));
408 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
409 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis *)));
409 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
410 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)));
410 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
411 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
411 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
412
412
413 QCOMPARE(m_dataset->seriesCount(seriesList.at(0)->type()),seriesCount);
413 QCOMPARE(m_dataset->seriesCount(seriesList.at(0)->type()),seriesCount);
414 TRY_COMPARE(spy0.count(), 0);
414 TRY_COMPARE(spy0.count(), 0);
@@ -434,8 +434,8 void tst_ChartDataSet::seriesIndex()
434 m_dataset->addSeries(series);
434 m_dataset->addSeries(series);
435 }
435 }
436
436
437 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis *,Domain*)));
437 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
438 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis *)));
438 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
439 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
439 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
440 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
440 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
441
441
@@ -520,10 +520,10 void tst_ChartDataSet::domain()
520 {
520 {
521 QFETCH(QAbstractSeries*, series);
521 QFETCH(QAbstractSeries*, series);
522
522
523 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis *, Domain *)));
523 QSignalSpy spy0(m_dataset, SIGNAL(axisAdded(QAbstractAxis*,Domain*)));
524 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis *)));
524 QSignalSpy spy1(m_dataset, SIGNAL(axisRemoved(QAbstractAxis*)));
525 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries *, Domain *)));
525 QSignalSpy spy2(m_dataset, SIGNAL(seriesAdded(QAbstractSeries*,Domain*)));
526 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries *)));
526 QSignalSpy spy3(m_dataset, SIGNAL(seriesRemoved(QAbstractSeries*)));
527
527
528 m_dataset->addSeries(series);
528 m_dataset->addSeries(series);
529 QVERIFY(m_dataset->domain(series));
529 QVERIFY(m_dataset->domain(series));
@@ -170,9 +170,9 void tst_QBarCategoriesAxis::append()
170 QBarCategoryAxis axis;
170 QBarCategoryAxis axis;
171
171
172 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
172 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
173 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
173 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
174 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
174 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
175 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
175 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
176
176
177 axis.append(categories);
177 axis.append(categories);
178
178
@@ -212,9 +212,9 void tst_QBarCategoriesAxis::at()
212 axis.append(categories);
212 axis.append(categories);
213
213
214 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
214 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
215 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
215 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
216 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
216 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
217 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
217 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
218
218
219 QCOMPARE(axis.at(index), string);
219 QCOMPARE(axis.at(index), string);
220
220
@@ -247,9 +247,9 void tst_QBarCategoriesAxis::categories()
247 QBarCategoryAxis axis;
247 QBarCategoryAxis axis;
248
248
249 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
249 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
250 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
250 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
251 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
251 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
252 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
252 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
253
253
254 axis.setCategories(categories);
254 axis.setCategories(categories);
255 QCOMPARE(axis.categories(), categories);
255 QCOMPARE(axis.categories(), categories);
@@ -287,9 +287,9 void tst_QBarCategoriesAxis::clear()
287 QCOMPARE(axis.categories(), categories);
287 QCOMPARE(axis.categories(), categories);
288
288
289 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
289 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
290 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
290 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
291 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
291 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
292 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
292 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
293
293
294 axis.clear();
294 axis.clear();
295 QCOMPARE(axis.categories(), QStringList());
295 QCOMPARE(axis.categories(), QStringList());
@@ -333,9 +333,9 void tst_QBarCategoriesAxis::count()
333 axis.setCategories(categories);
333 axis.setCategories(categories);
334
334
335 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
335 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
336 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
336 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
337 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
337 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
338 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
338 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
339
339
340 QCOMPARE(axis.count(), count);
340 QCOMPARE(axis.count(), count);
341
341
@@ -370,9 +370,9 void tst_QBarCategoriesAxis::insert()
370 axis.append(categories);
370 axis.append(categories);
371
371
372 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
372 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
373 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
373 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
374 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
374 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
375 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
375 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
376
376
377 axis.insert(index, category);
377 axis.insert(index, category);
378 QCOMPARE(axis.at(index),category);
378 QCOMPARE(axis.at(index),category);
@@ -410,9 +410,9 void tst_QBarCategoriesAxis::remove()
410 int rangeCount = maxCount + minCount;
410 int rangeCount = maxCount + minCount;
411
411
412 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
412 QSignalSpy spy0(&axis, SIGNAL(categoriesChanged()));
413 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString const&)));
413 QSignalSpy spy1(&axis, SIGNAL(maxChanged(QString)));
414 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString const&)));
414 QSignalSpy spy2(&axis, SIGNAL(minChanged(QString)));
415 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString const&, QString const&)));
415 QSignalSpy spy3(&axis, SIGNAL(rangeChanged(QString,QString)));
416
416
417 axis.remove(category);
417 axis.remove(category);
418 QCOMPARE(axis.categories(),result);
418 QCOMPARE(axis.categories(),result);
@@ -437,9 +437,9 void tst_QBarCategoriesAxis::max_raw()
437 QFETCH(QString, max);
437 QFETCH(QString, max);
438
438
439 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
439 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
440 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString const&)));
440 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString)));
441 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString const&)));
441 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString)));
442 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString const&, QString const&)));
442 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString,QString)));
443
443
444 m_baraxis->setMax(max);
444 m_baraxis->setMax(max);
445 QCOMPARE(m_baraxis->max(), max);
445 QCOMPARE(m_baraxis->max(), max);
@@ -488,9 +488,9 void tst_QBarCategoriesAxis::min_raw()
488 QFETCH(QString, min);
488 QFETCH(QString, min);
489
489
490 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
490 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
491 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString const&)));
491 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString)));
492 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString const&)));
492 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString)));
493 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString const&, QString const&)));
493 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString,QString)));
494
494
495 m_baraxis->setMin(min);
495 m_baraxis->setMin(min);
496 QCOMPARE(m_baraxis->min(), min);
496 QCOMPARE(m_baraxis->min(), min);
@@ -543,9 +543,9 void tst_QBarCategoriesAxis::range_raw()
543 QFETCH(QString, max);
543 QFETCH(QString, max);
544
544
545 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
545 QSignalSpy spy0(m_baraxis, SIGNAL(categoriesChanged()));
546 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString const&)));
546 QSignalSpy spy1(m_baraxis, SIGNAL(maxChanged(QString)));
547 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString const&)));
547 QSignalSpy spy2(m_baraxis, SIGNAL(minChanged(QString)));
548 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString const&, QString const&)));
548 QSignalSpy spy3(m_baraxis, SIGNAL(rangeChanged(QString,QString)));
549
549
550 m_baraxis->setRange(min, max);
550 m_baraxis->setRange(min, max);
551 QCOMPARE(m_baraxis->min(), min);
551 QCOMPARE(m_baraxis->min(), min);
@@ -598,7 +598,7 void tst_QBarCategoriesAxis::noautoscale()
598
598
599 QSignalSpy spy0(m_baraxis, SIGNAL(maxChanged(QString)));
599 QSignalSpy spy0(m_baraxis, SIGNAL(maxChanged(QString)));
600 QSignalSpy spy1(m_baraxis, SIGNAL(minChanged(QString)));
600 QSignalSpy spy1(m_baraxis, SIGNAL(minChanged(QString)));
601 QSignalSpy spy2(m_baraxis, SIGNAL(rangeChanged(QString, QString)));
601 QSignalSpy spy2(m_baraxis, SIGNAL(rangeChanged(QString,QString)));
602
602
603 m_baraxis->setRange(min, max);
603 m_baraxis->setRange(min, max);
604 QCOMPARE(m_baraxis->min(),min);
604 QCOMPARE(m_baraxis->min(),min);
@@ -627,7 +627,7 void tst_QBarCategoriesAxis::autoscale()
627
627
628 QSignalSpy spy0(m_baraxis, SIGNAL(maxChanged(QString)));
628 QSignalSpy spy0(m_baraxis, SIGNAL(maxChanged(QString)));
629 QSignalSpy spy1(m_baraxis, SIGNAL(minChanged(QString)));
629 QSignalSpy spy1(m_baraxis, SIGNAL(minChanged(QString)));
630 QSignalSpy spy2(m_baraxis, SIGNAL(rangeChanged(QString, QString)));
630 QSignalSpy spy2(m_baraxis, SIGNAL(rangeChanged(QString,QString)));
631
631
632 QCOMPARE(m_baraxis->min(),QString());
632 QCOMPARE(m_baraxis->min(),QString());
633 QCOMPARE(m_baraxis->max(),QString());
633 QCOMPARE(m_baraxis->max(),QString());
@@ -221,7 +221,7 void tst_QBarSeries::take()
221 QVERIFY(m_barseries_with_sets->count() == count);
221 QVERIFY(m_barseries_with_sets->count() == count);
222
222
223 QSignalSpy countSpy(m_barseries_with_sets,SIGNAL(countChanged()));
223 QSignalSpy countSpy(m_barseries_with_sets,SIGNAL(countChanged()));
224 QSignalSpy removedSpy(m_barseries_with_sets,SIGNAL(barsetsRemoved(QList<QBarSet *>)));
224 QSignalSpy removedSpy(m_barseries_with_sets,SIGNAL(barsetsRemoved(QList<QBarSet*>)));
225
225
226 for (int i=0; i<m_testSets.count(); i++) {
226 for (int i=0; i<m_testSets.count(); i++) {
227 QBarSet* set = m_testSets.at(i);
227 QBarSet* set = m_testSets.at(i);
@@ -124,7 +124,7 void tst_QCategoryAxis::max_raw()
124
124
125 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
125 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
126 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
126 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
127 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal, qreal)));
127 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal,qreal)));
128
128
129 m_categoryaxis->setMax(max);
129 m_categoryaxis->setMax(max);
130 QVERIFY2(qFuzzyIsNull(m_categoryaxis->max() - max), "Not equal");
130 QVERIFY2(qFuzzyIsNull(m_categoryaxis->max() - max), "Not equal");
@@ -172,7 +172,7 void tst_QCategoryAxis::min_raw()
172
172
173 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
173 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
174 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
174 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
175 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal, qreal)));
175 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal,qreal)));
176
176
177 m_categoryaxis->setMin(min);
177 m_categoryaxis->setMin(min);
178 QVERIFY2(qFuzzyIsNull(m_categoryaxis->min() - min), "Not equal");
178 QVERIFY2(qFuzzyIsNull(m_categoryaxis->min() - min), "Not equal");
@@ -225,7 +225,7 void tst_QCategoryAxis::range_raw()
225
225
226 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
226 QSignalSpy spy0(m_categoryaxis, SIGNAL(maxChanged(qreal)));
227 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
227 QSignalSpy spy1(m_categoryaxis, SIGNAL(minChanged(qreal)));
228 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal, qreal)));
228 QSignalSpy spy2(m_categoryaxis, SIGNAL(rangeChanged(qreal,qreal)));
229
229
230 m_categoryaxis->setRange(min, max);
230 m_categoryaxis->setRange(min, max);
231 QVERIFY2(qFuzzyIsNull(m_categoryaxis->min() - min), "Min not equal");
231 QVERIFY2(qFuzzyIsNull(m_categoryaxis->min() - min), "Min not equal");
@@ -134,7 +134,7 void tst_QDateTimeAxis::max_raw()
134
134
135 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
135 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
136 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
136 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
137 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime, QDateTime)));
137 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime,QDateTime)));
138
138
139 m_dateTimeAxisX->setMax(max);
139 m_dateTimeAxisX->setMax(max);
140
140
@@ -193,7 +193,7 void tst_QDateTimeAxis::min_raw()
193
193
194 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
194 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
195 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
195 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
196 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime, QDateTime)));
196 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime,QDateTime)));
197
197
198 m_dateTimeAxisX->setMin(min);
198 m_dateTimeAxisX->setMin(min);
199
199
@@ -269,7 +269,7 void tst_QDateTimeAxis::range_raw()
269
269
270 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
270 QSignalSpy spy0(m_dateTimeAxisX, SIGNAL(maxChanged(QDateTime)));
271 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
271 QSignalSpy spy1(m_dateTimeAxisX, SIGNAL(minChanged(QDateTime)));
272 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime, QDateTime)));
272 QSignalSpy spy2(m_dateTimeAxisX, SIGNAL(rangeChanged(QDateTime,QDateTime)));
273
273
274 m_dateTimeAxisX->setRange(min, max);
274 m_dateTimeAxisX->setRange(min, max);
275
275
@@ -114,7 +114,7 void tst_QHorizontalPercentBarSeries::mouseclicked()
114
114
115 QList<QBarSet*> barSets = series->barSets();
115 QList<QBarSet*> barSets = series->barSets();
116
116
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int, QBarSet*)));
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int,QBarSet*)));
118
118
119 QChartView view(new QChart());
119 QChartView view(new QChart());
120 view.resize(400,300);
120 view.resize(400,300);
@@ -247,7 +247,7 void tst_QHorizontalPercentBarSeries::mousehovered()
247
247
248 QList<QBarSet*> barSets = series->barSets();
248 QList<QBarSet*> barSets = series->barSets();
249
249
250 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool, QBarSet*)));
250 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool,QBarSet*)));
251
251
252 QChartView view(new QChart());
252 QChartView view(new QChart());
253 view.resize(400,300);
253 view.resize(400,300);
@@ -114,7 +114,7 void tst_QHorizontalStackedBarSeries::mouseclicked()
114
114
115 QList<QBarSet*> barSets = series->barSets();
115 QList<QBarSet*> barSets = series->barSets();
116
116
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int, QBarSet*)));
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int,QBarSet*)));
118
118
119 QChartView view(new QChart());
119 QChartView view(new QChart());
120 view.resize(400,300);
120 view.resize(400,300);
@@ -252,7 +252,7 void tst_QHorizontalStackedBarSeries::mousehovered()
252
252
253 QList<QBarSet*> barSets = series->barSets();
253 QList<QBarSet*> barSets = series->barSets();
254
254
255 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool, QBarSet*)));
255 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool,QBarSet*)));
256
256
257 QChartView view(new QChart());
257 QChartView view(new QChart());
258 view.resize(400,300);
258 view.resize(400,300);
@@ -114,7 +114,7 void tst_QPercentBarSeries::mouseclicked()
114
114
115 QList<QBarSet*> barSets = series->barSets();
115 QList<QBarSet*> barSets = series->barSets();
116
116
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int, QBarSet*)));
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int,QBarSet*)));
118
118
119 QChartView view(new QChart());
119 QChartView view(new QChart());
120 view.resize(400,300);
120 view.resize(400,300);
@@ -249,7 +249,7 void tst_QPercentBarSeries::mousehovered()
249
249
250 QList<QBarSet*> barSets = series->barSets();
250 QList<QBarSet*> barSets = series->barSets();
251
251
252 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool, QBarSet*)));
252 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool,QBarSet*)));
253
253
254 QChartView view(new QChart());
254 QChartView view(new QChart());
255 view.resize(400,300);
255 view.resize(400,300);
@@ -114,7 +114,7 void tst_QStackedBarSeries::mouseclicked()
114
114
115 QList<QBarSet*> barSets = series->barSets();
115 QList<QBarSet*> barSets = series->barSets();
116
116
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int, QBarSet*)));
117 QSignalSpy seriesSpy(series,SIGNAL(clicked(int,QBarSet*)));
118
118
119 QChartView view(new QChart());
119 QChartView view(new QChart());
120 view.resize(400,300);
120 view.resize(400,300);
@@ -252,7 +252,7 void tst_QStackedBarSeries::mousehovered()
252
252
253 QList<QBarSet*> barSets = series->barSets();
253 QList<QBarSet*> barSets = series->barSets();
254
254
255 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool, QBarSet*)));
255 QSignalSpy seriesSpy(series,SIGNAL(hovered(bool,QBarSet*)));
256
256
257 QChartView view(new QChart());
257 QChartView view(new QChart());
258 view.resize(400,300);
258 view.resize(400,300);
@@ -132,7 +132,7 void tst_QValueAxis::max_raw()
132
132
133 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
133 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
134 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
134 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
135 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
135 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
136
136
137 m_valuesaxis->setMax(max);
137 m_valuesaxis->setMax(max);
138 QVERIFY2(qFuzzyIsNull(m_valuesaxis->max() - max), "Not equal");
138 QVERIFY2(qFuzzyIsNull(m_valuesaxis->max() - max), "Not equal");
@@ -181,7 +181,7 void tst_QValueAxis::min_raw()
181
181
182 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
182 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
183 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
183 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
184 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
184 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
185
185
186 m_valuesaxis->setMin(min);
186 m_valuesaxis->setMin(min);
187 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Not equal");
187 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Not equal");
@@ -250,7 +250,7 void tst_QValueAxis::niceNumbersEnabled()
250
250
251 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
251 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
252 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
252 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
253 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
253 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
254
254
255 m_valuesaxis->setNiceNumbersEnabled(niceNumbersEnabled);
255 m_valuesaxis->setNiceNumbersEnabled(niceNumbersEnabled);
256 QCOMPARE(m_valuesaxis->niceNumbersEnabled(), niceNumbersEnabled);
256 QCOMPARE(m_valuesaxis->niceNumbersEnabled(), niceNumbersEnabled);
@@ -284,7 +284,7 void tst_QValueAxis::range_raw()
284
284
285 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
285 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
286 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
286 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
287 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
287 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
288
288
289 m_valuesaxis->setRange(min, max);
289 m_valuesaxis->setRange(min, max);
290 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Min not equal");
290 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Min not equal");
@@ -336,7 +336,7 void tst_QValueAxis::ticksCount()
336
336
337 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
337 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
338 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
338 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
339 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
339 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
340
340
341 m_valuesaxis->setTickCount(ticksCount);
341 m_valuesaxis->setTickCount(ticksCount);
342 QCOMPARE(m_valuesaxis->tickCount(), ticksCount);
342 QCOMPARE(m_valuesaxis->tickCount(), ticksCount);
@@ -368,7 +368,7 void tst_QValueAxis::noautoscale()
368
368
369 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
369 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
370 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
370 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
371 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
371 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
372
372
373 m_valuesaxis->setRange(min, max);
373 m_valuesaxis->setRange(min, max);
374 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Min not equal");
374 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min() - min), "Min not equal");
@@ -394,7 +394,7 void tst_QValueAxis::autoscale()
394 {
394 {
395 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
395 QSignalSpy spy0(m_valuesaxis, SIGNAL(maxChanged(qreal)));
396 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
396 QSignalSpy spy1(m_valuesaxis, SIGNAL(minChanged(qreal)));
397 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal, qreal)));
397 QSignalSpy spy2(m_valuesaxis, SIGNAL(rangeChanged(qreal,qreal)));
398
398
399 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min()), "Min not equal");
399 QVERIFY2(qFuzzyIsNull(m_valuesaxis->min()), "Min not equal");
400 QVERIFY2(qFuzzyIsNull(m_valuesaxis->max()), "Max not equal");
400 QVERIFY2(qFuzzyIsNull(m_valuesaxis->max()), "Max not equal");
@@ -97,7 +97,7 void tst_QXYSeries::append_raw_data()
97 void tst_QXYSeries::append_raw()
97 void tst_QXYSeries::append_raw()
98 {
98 {
99 QFETCH(QList<QPointF>, points);
99 QFETCH(QList<QPointF>, points);
100 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
100 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
101 QSignalSpy addedSpy(m_series, SIGNAL(pointAdded(int)));
101 QSignalSpy addedSpy(m_series, SIGNAL(pointAdded(int)));
102 m_series->append(points);
102 m_series->append(points);
103 TRY_COMPARE(spy0.count(), 0);
103 TRY_COMPARE(spy0.count(), 0);
@@ -160,7 +160,7 void tst_QXYSeries::count_raw()
160 {
160 {
161 QFETCH(int, count);
161 QFETCH(int, count);
162
162
163 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
163 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
164
164
165 for(int i=0 ; i< count; ++i)
165 for(int i=0 ; i< count; ++i)
166 m_series->append(i,i);
166 m_series->append(i,i);
@@ -177,7 +177,7 void tst_QXYSeries::remove_raw_data()
177 void tst_QXYSeries::remove_raw()
177 void tst_QXYSeries::remove_raw()
178 {
178 {
179 QFETCH(QList<QPointF>, points);
179 QFETCH(QList<QPointF>, points);
180 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
180 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
181 m_series->append(points);
181 m_series->append(points);
182 TRY_COMPARE(spy0.count(), 0);
182 TRY_COMPARE(spy0.count(), 0);
183 QCOMPARE(m_series->points(), points);
183 QCOMPARE(m_series->points(), points);
@@ -231,7 +231,7 void tst_QXYSeries::clear_raw_data()
231 void tst_QXYSeries::clear_raw()
231 void tst_QXYSeries::clear_raw()
232 {
232 {
233 QFETCH(QList<QPointF>, points);
233 QFETCH(QList<QPointF>, points);
234 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
234 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
235 m_series->append(points);
235 m_series->append(points);
236 TRY_COMPARE(spy0.count(), 0);
236 TRY_COMPARE(spy0.count(), 0);
237 QCOMPARE(m_series->points(), points);
237 QCOMPARE(m_series->points(), points);
@@ -360,7 +360,7 void tst_QXYSeries::oper()
360 {
360 {
361 QFETCH(QList<QPointF>, points);
361 QFETCH(QList<QPointF>, points);
362
362
363 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
363 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
364
364
365 foreach (const QPointF& point,points)
365 foreach (const QPointF& point,points)
366 {
366 {
@@ -385,7 +385,7 void tst_QXYSeries::pen()
385 {
385 {
386 QFETCH(QPen, pen);
386 QFETCH(QPen, pen);
387
387
388 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
388 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
389 m_series->setPen(pen);
389 m_series->setPen(pen);
390
390
391 TRY_COMPARE(spy0.count(), 0);
391 TRY_COMPARE(spy0.count(), 0);
@@ -418,7 +418,7 void tst_QXYSeries::pointsVisible_raw_data()
418 void tst_QXYSeries::pointsVisible_raw()
418 void tst_QXYSeries::pointsVisible_raw()
419 {
419 {
420 QFETCH(bool, pointsVisible);
420 QFETCH(bool, pointsVisible);
421 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF const&)));
421 QSignalSpy spy0(m_series, SIGNAL(clicked(QPointF)));
422 m_series->setPointsVisible(pointsVisible);
422 m_series->setPointsVisible(pointsVisible);
423 TRY_COMPARE(spy0.count(), 0);
423 TRY_COMPARE(spy0.count(), 0);
424 QCOMPARE(m_series->pointsVisible(), pointsVisible);
424 QCOMPARE(m_series->pointsVisible(), pointsVisible);
@@ -265,7 +265,7 void Engine::setupXYSeries(QXYSeries *xyseries, const QList<int>& columns, int c
265 mapper->setRowCount(maxRow - minRow + 1);
265 mapper->setRowCount(maxRow - minRow + 1);
266 m_chart->addSeries(xyseries);
266 m_chart->addSeries(xyseries);
267 xyseries->setName(QString("Series %1").arg(m_chart->series().count()));
267 xyseries->setName(QString("Series %1").arg(m_chart->series().count()));
268 QObject::connect(xyseries,SIGNAL(clicked(const QPointF&)),this,SIGNAL(selected()));
268 QObject::connect(xyseries,SIGNAL(clicked(QPointF)),this,SIGNAL(selected()));
269 const QModelIndexList& list = m_selection->selectedIndexes();
269 const QModelIndexList& list = m_selection->selectedIndexes();
270 QModelIndexList result;
270 QModelIndexList result;
271 foreach (const QModelIndex& index, list) {
271 foreach (const QModelIndex& index, list) {
@@ -223,7 +223,7 void MainWindow::createTable()
223 {
223 {
224 m_table->setModel(m_engine->model());
224 m_table->setModel(m_engine->model());
225 m_table->setSelectionModel(m_engine->selectionModel());
225 m_table->setSelectionModel(m_engine->selectionModel());
226 QObject::connect(m_table->selectionModel(),SIGNAL(selectionChanged(const QItemSelection&, const QItemSelection&)), this,SLOT(updateUI()));
226 QObject::connect(m_table->selectionModel(),SIGNAL(selectionChanged(QItemSelection,QItemSelection)), this,SLOT(updateUI()));
227 }
227 }
228
228
229 void MainWindow::updateUI()
229 void MainWindow::updateUI()
General Comments 0
You need to be logged in to leave comments. Login now