From 86b5fb2a79947961ae7566880d9a0bd2896ff93c 2012-03-21 13:00:53 From: Michal Klocek Date: 2012-03-21 13:00:53 Subject: [PATCH] Add missing files from previous commit --- diff --git a/src/chart.cpp b/src/chart.cpp new file mode 100644 index 0000000..50e95f4 --- /dev/null +++ b/src/chart.cpp @@ -0,0 +1,61 @@ +#include "chart_p.h" +#include "chartpresenter_p.h" + +QTCOMMERCIALCHART_BEGIN_NAMESPACE + + +Chart::Chart(ChartPresenter *presenter):QObject(presenter), + m_animator(0), + m_presenter(presenter) +{ +}; + +void Chart::setAnimator(ChartAnimator* animator) +{ + m_animator=animator; +} + +ChartAnimator* Chart::animator() const +{ + return m_animator; +} + +ChartPresenter* Chart::presenter() const +{ + return m_presenter; +} + +void Chart::handleGeometryChanged(const QRectF& rect) +{ + Q_UNUSED(rect); + qWarning()<<"Slot not implemented"; +} + +void Chart::handleDomainChanged(qreal minX,qreal maxX,qreal minY,qreal maxY) +{ + Q_UNUSED(minX); + Q_UNUSED(maxX); + Q_UNUSED(minY); + Q_UNUSED(maxY); + qWarning()<<"Slot not implemented"; +} + +void Chart::rangeXChanged(qreal min, qreal max, int tickXCount) +{ + Q_UNUSED(min); + Q_UNUSED(max); + Q_UNUSED(tickXCount); + qWarning()<<"Slot not implemented"; +} + +void Chart::rangeYChanged(qreal min, qreal max, int tickYCount) +{ + Q_UNUSED(min); + Q_UNUSED(max); + Q_UNUSED(tickYCount); + qWarning()<<"Slot not implemented"; +} + +#include "moc_chart_p.cpp" + +QTCOMMERCIALCHART_END_NAMESPACE diff --git a/src/chart_p.h b/src/chart_p.h new file mode 100644 index 0000000..e0e4052 --- /dev/null +++ b/src/chart_p.h @@ -0,0 +1,35 @@ +#ifndef CHART_H_ +#define CHART_H_ + +#include "qchartglobal.h" +#include + +QTCOMMERCIALCHART_BEGIN_NAMESPACE + +class ChartAnimator; +class ChartPresenter; + +class Chart: public QObject +{ + Q_OBJECT +public: + explicit Chart(ChartPresenter *presenter); + +public slots: + virtual void handleGeometryChanged(const QRectF& rect); + virtual void handleDomainChanged(qreal minX,qreal maxX,qreal minY,qreal maxY); + virtual void rangeXChanged(qreal min, qreal max, int tickXCount); + virtual void rangeYChanged(qreal min, qreal max, int tickYCount); + + void setAnimator(ChartAnimator* animator); + ChartAnimator* animator() const; + ChartPresenter* presenter() const; + +private: + ChartAnimator* m_animator; + ChartPresenter* m_presenter; +}; + +QTCOMMERCIALCHART_END_NAMESPACE + +#endif