diff --git a/geometry/vdetail.cpp b/geometry/vdetail.cpp index 6bfdf3add..105c90cba 100644 --- a/geometry/vdetail.cpp +++ b/geometry/vdetail.cpp @@ -70,7 +70,7 @@ bool VDetail::Containes(const qint64 &id) const return false; } -VNodeDetail &VDetail::operator [](int indx) +VNodeDetail &VDetail::operator [](ptrdiff_t indx) { return nodes[indx]; } diff --git a/geometry/vdetail.h b/geometry/vdetail.h index c715ea8da..c85b411a0 100644 --- a/geometry/vdetail.h +++ b/geometry/vdetail.h @@ -46,7 +46,7 @@ public: void Clear(); inline qint32 CountNode() const {return nodes.size();} bool Containes(const qint64 &id)const; - VNodeDetail & operator[](int indx); + VNodeDetail & operator[](ptrdiff_t indx); inline QString getName() const {return name;} inline void setName(const QString &value) {name = value;} inline qreal getMx() const {return mx;} diff --git a/geometry/vsplinepath.cpp b/geometry/vsplinepath.cpp index 23c5d45b0..01eb67bc4 100644 --- a/geometry/vsplinepath.cpp +++ b/geometry/vsplinepath.cpp @@ -146,7 +146,7 @@ VSplinePath &VSplinePath::operator =(const VSplinePath &path) return *this; } -VSplinePoint & VSplinePath::operator[](int indx) +VSplinePoint & VSplinePath::operator[](ptrdiff_t indx) { return path[indx]; } diff --git a/geometry/vsplinepath.h b/geometry/vsplinepath.h index 94279c109..77d7c956d 100644 --- a/geometry/vsplinepath.h +++ b/geometry/vsplinepath.h @@ -74,7 +74,7 @@ public: inline void setKCurve(const qreal &value) {kCurve = value;} inline const QVector *GetPoint() const {return &path;} VSplinePath &operator=(const VSplinePath &path); - VSplinePoint &operator[](int indx); + VSplinePoint &operator[](ptrdiff_t indx); inline Draw::Draws getMode() const {return mode;} inline void setMode(const Draw::Draws &value) {mode = value;}