CMP EMBEDDED.COM

Login | Register     Welcome Guest   IPS  
HOME DESIGN PRODUCTS COLUMNS E-LEARNING CONFERENCES CODE FORUMS/BLOGS NEWSLETTERS CONTACT FEATURES RSS RSS

Listing 2 : Additional features of the data structures necessary to support erase
struct drawableStruct
{
Area area;
int color;
DrawableType type;
Container *parentPtr;
Drawable *nextContainedPtr;
Boolean dirty;
Drawable *nextDirtyDrawablePtr;
Container *oldParentPtr;
Area oldArea;
};
struct boxStruct
{
Drawable drawable;
Boolean filled;
int fillColor;
Boolean oldFilled;
};
struct circleStruct
{
Drawable drawable;
};
struct lineStruct
{
Drawable drawable;
int x1;
int y1;
int x2;
int y2;
int oldX1;
int oldY1;
int oldX2;
int oldY2;
};
struct textStruct
{
Drawable drawable;
char *string;
};
struct containerStruct
{
Drawable drawable;
Drawable *containedListPtr;
/* 
The absolute location is maintained to optimize drawing the 
contained objects.
*/
int absoluteLeft;
int absoluteTop;
Boolean visible;
};

Back

Embedded.com Career Center
Ready for a change?
SEARCH JOBS

Browse all jobs

SPONSOR
RECENT JOB POSTINGS





 :