|
Public Member Functions |
|
void | Destroy () |
| | Releases all resources.
|
| BOOL | Move (LPPOINT pPt) |
| | Moves objects if needed.
|
| virtual BOOL | OnMouseMove (UINT uFlags, LPPOINT pPt) |
| | Call in response to a WM_MOUSEMOVE message.
|
| virtual BOOL | OnLButtonDown (UINT uFlags, LPPOINT pPt) |
| | Call in response to a WM_LBUTTONDOWN message.
|
| virtual BOOL | OnLButtonUp (UINT uFlags, LPPOINT pPt) |
| | Call in response to a WM_LBUTTONUP message.
|
| BOOL | SetCursor (LPPOINT pt) |
| | Sets the needed mouse cursor.
|
| virtual HCURSOR | GetCursor (DWORD dwCursor) |
| | Returns the appropriate mouse cursor for a user action.
|
| DWORD | GetCursorFlags (LPPOINT pPt) |
| | Returns the user interaction code for a particular cursor position.
|
| BOOL | Draw (HDC hDC, LPRECT pRect) |
| | Draws a select box around the active area.
|
|
| CMovableObj (LPRECT pRect=NULL) |
| | Default constructor.
|
|
virtual | ~CMovableObj () |
| | Destructor.
|
|
LPRECT | GetRect () |
| | Returns the current size and position.
|
|
| operator LPRECT () |
| | Returns the current size and position.
|
| double | SetAngle (DWORD i, double v) |
| | Sets the object rotation angle for the specified index.
|
| void | SetDistance (double v) |
| | Sets the distance for resolution calculations.
|
| double | GetAngle (DWORD i) |
| | Returns the specified angle value.
|
|
double | GetDistance () |
| | Returns the distance value used in resolution calculations.
|
|
long | GetX () |
| | Returns object horizontal offset.
|
|
long | GetY () |
| | Returns object vertical offset.
|
| void | SetRect (LPRECT pRect) |
| | Sets the object size and position.
|
| void | GetRect (LPRECT pRect) |
| | Returns the objects size and position.
|
|
long | GetWidth () |
| | Returns the object width.
|
|
long | GetHeight () |
| | Returns the object height.
|
| void | SetOffset (long x, long y) |
| | Sets the objects horizontal and vertical offset.
|
|
long | Left () |
| | Returns the horizontal offset of the objects left side.
|
|
long | Top () |
| | Returns the horizontal offset of the objects top side.
|
|
long | Right () |
| | Returns the horizontal offset of the objects right side.
|
|
long | Bottom () |
| | Returns the horizontal offset of the objects bottom side.
|
| virtual BOOL | OnDraw (HDC hDc, LPRECT pRect) |
| | Called when the object needs redrawing.
|
| void | Select (BOOL bSelect) |
| | Set the select state.
|
|
BOOL | IsSelected () |
| | Returns non-zero if object is selected.
|
| BOOL | PtInRect (LPPOINT pt) |
| | Returns non-zero if the specified point is within the object bounds.
|
This class assists in graphical editor building by managing user interactions with elements. Simple interactions such as movement, rectangular resizing, and rotation are supported.