33 lines
493 B
C++
33 lines
493 B
C++
#ifndef _POLYPOINT_HPP_
|
|
#define _POLYPOINT_HPP_
|
|
#include <mdiwin/point.hpp>
|
|
|
|
class PolyPoint
|
|
{
|
|
public:
|
|
enum {MaxPoint=4};
|
|
PolyPoint(void);
|
|
PolyPoint(const PolyPoint &somePolyPoint);
|
|
~PolyPoint();
|
|
Point &operator[](unsigned point);
|
|
private:
|
|
Point mPolyPoint[MaxPoint];
|
|
};
|
|
|
|
inline
|
|
PolyPoint::PolyPoint(void)
|
|
{
|
|
}
|
|
|
|
inline
|
|
PolyPoint::~PolyPoint()
|
|
{
|
|
}
|
|
|
|
inline
|
|
Point &PolyPoint::operator[](unsigned point)
|
|
{
|
|
if(point>=MaxPoint)return mPolyPoint[MaxPoint-1];
|
|
return mPolyPoint[point];
|
|
}
|
|
#endif |