xref: /haiku/src/tests/kits/interface/bpolygon/DummyPolygon.h (revision 571d840abfdf03de583b26fefd2066ee75b25cf4)
1f7081347Sjrand /*
2*571d840aSOliver Tappe 	$Id: DummyPolygon.h 2067 2002-11-23 04:42:57Z jrand $
3f7081347Sjrand 
4f7081347Sjrand 	This file contains the definition of a dummy BPolygon class.
5f7081347Sjrand 	It is used in order to get access to the private points of the
6f7081347Sjrand 	BPolygon.  The BPolygon class itself does not allow you to extract
7f7081347Sjrand 	these points.
8f7081347Sjrand 
9f7081347Sjrand 	This is a hack in order to properly test BPolygon.  It is highly
10f7081347Sjrand 	dependent on the private structure of BPolygon and is likely to break
11f7081347Sjrand 	if this structure is changed substantially in the future.  However,
12f7081347Sjrand 	it is the only effective way to test BPolygon.
13f7081347Sjrand 
14f7081347Sjrand 	*/
15f7081347Sjrand 
16f7081347Sjrand #ifndef DUMMYPOLYGON_H
17f7081347Sjrand #define DUMMYPOLYGON_H
18f7081347Sjrand 
19f7081347Sjrand 
20f7081347Sjrand #include <Rect.h>
21f7081347Sjrand 
22f7081347Sjrand 
23f7081347Sjrand class BPoint;
24f7081347Sjrand 
25f7081347Sjrand 
26f7081347Sjrand class DummyPolygon {
27f7081347Sjrand 
28f7081347Sjrand public:
29f7081347Sjrand 	DummyPolygon();
30f7081347Sjrand 	virtual ~DummyPolygon();
31f7081347Sjrand 
32f7081347Sjrand 	const BPoint *GetPoints(void);
33f7081347Sjrand 
34f7081347Sjrand /*----- Private or reserved -----------------------------------------*/
35f7081347Sjrand private:
36f7081347Sjrand                 BRect   fBounds;
37f7081347Sjrand                 int32   fCount;
38f7081347Sjrand                 BPoint  *fPts;
39f7081347Sjrand };
40f7081347Sjrand 
41f7081347Sjrand #endif	// DUMMYPOLYGON_H
42f7081347Sjrand 
43f7081347Sjrand 
44f7081347Sjrand 
45f7081347Sjrand 
46f7081347Sjrand 
47f7081347Sjrand 
48