summaryrefslogtreecommitdiffstats
path: root/src/datavisualization/data/barrenderitem_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/datavisualization/data/barrenderitem_p.h')
-rw-r--r--src/datavisualization/data/barrenderitem_p.h20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/datavisualization/data/barrenderitem_p.h b/src/datavisualization/data/barrenderitem_p.h
index 5a44e2fd..f44ba2b4 100644
--- a/src/datavisualization/data/barrenderitem_p.h
+++ b/src/datavisualization/data/barrenderitem_p.h
@@ -47,7 +47,15 @@ public:
inline const QPoint &position() const { return m_position; }
// Actual cached data value of the bar (needed to trigger label reformats)
- inline void setValue(float value);
+ inline void setValue(float value)
+ {
+ m_value = value;
+ // Force reformatting on next access by setting label string to null string
+ if (!m_sliceLabel.isNull())
+ setSliceLabel(QString());
+ if (!m_selectionLabel.isNull())
+ setSelectionLabel(QString());
+ }
inline float value() const { return m_value; }
// Normalized bar height
@@ -77,16 +85,6 @@ protected:
friend class QBarDataItem;
};
-void BarRenderItem::setValue(float value)
-{
- m_value = value;
- // Force reformatting on next access by setting label string to null string
- if (!m_sliceLabel.isNull())
- setSliceLabel(QString());
- if (!m_selectionLabel.isNull())
- setSelectionLabel(QString());
-}
-
typedef QVector<BarRenderItem> BarRenderItemRow;
typedef QVector<BarRenderItemRow> BarRenderItemArray;