##// END OF EJS Templates
Compile fix
Compile fix

File last commit:

r71:1f789ed92d7b
r124:af6b508a43ab
Show More
qchartseries.cpp
34 lines | 849 B | text/x-c | CppLexer
/ src / qchartseries.cpp
sauimone
Refactored series creation.
r62 #include "qchartglobal.h"
#include "qchartseries.h"
#include "barchartseries.h"
#include "qxychartseries.h"
QTCOMMERCIALCHART_BEGIN_NAMESPACE
QChartSeries* QChartSeries::create(QChartSeriesType type, QObject* parent)
{
sauimone
Improved bar chart series
r71 qDebug() << "QChartSeries::create";
sauimone
Refactored series creation.
r62 // TODO: Other types
switch (type) {
case QChartSeries::SeriesTypeLine: {
QXYChartSeries* s = QXYChartSeries::create(parent); // TODO: do we need create method for derived implementations?
return s;
}
case QChartSeries::SeriesTypePie: {
return 0;
}
case QChartSeries::SeriesTypeScatter: {
return 0;
}
case QChartSeries::SeriesTypeBar: {
BarChartSeries* s = new BarChartSeries(parent);
return s;
}
default:
return 0;
}
}
sauimone
Improved bar chart series
r71 #include "moc_qchartseries.cpp"
sauimone
Refactored series creation.
r62 QTCOMMERCIALCHART_END_NAMESPACE