diff --git a/src/xlsx/xlsxcell.cpp b/src/xlsx/xlsxcell.cpp index 947a590..d27c066 100644 --- a/src/xlsx/xlsxcell.cpp +++ b/src/xlsx/xlsxcell.cpp @@ -58,6 +58,14 @@ Cell::Cell(const QVariant &data, DataType type, Format *format, Worksheet *paren d_ptr->parent = parent; } +/*! + * Destroys the Cell and cleans up. + */ +Cell::~Cell() +{ + delete d_ptr; +} + /*! * Return the dataType of this Cell */ diff --git a/src/xlsx/xlsxcell.h b/src/xlsx/xlsxcell.h index 33af031..2db413d 100644 --- a/src/xlsx/xlsxcell.h +++ b/src/xlsx/xlsxcell.h @@ -57,12 +57,12 @@ public: bool isDateTime() const; QDateTime dateTime() const; + ~Cell(); private: friend class Worksheet; friend class WorksheetPrivate; Cell(const QVariant &data=QVariant(), DataType type=Blank, Format *format=0, Worksheet *parent=0); - CellPrivate * const d_ptr; };