Using QXlsx::CellRange instead of the private XlsxCellRange

This commit is contained in:
Debao Zhang
2013-10-29 17:24:44 +08:00
parent e283a0af7f
commit 0155cc5409
5 changed files with 44 additions and 57 deletions
+12
View File
@@ -45,10 +45,22 @@ public:
inline int rowCount() const { return bottom - top + 1; }
inline int columnCount() const { return right - left + 1; }
inline bool operator ==(const CellRange &other) const
{
return top==other.top && bottom==other.bottom
&& left == other.left && right == other.right;
}
inline bool operator !=(const CellRange &other) const
{
return top!=other.top || bottom!=other.bottom
|| left != other.left || right != other.right;
}
private:
int top, left, bottom, right;
};
QT_END_NAMESPACE_XLSX
Q_DECLARE_TYPEINFO(QXlsx::CellRange, Q_MOVABLE_TYPE);
#endif // QXLSX_XLSXCELLRANGE_H