#include <cursor.h>
List of all members.
Detailed Description
Cursor class manages mouse cursor handling
Definition at line 84 of file cursor.h.
Constructor & Destructor Documentation
virtual FIFE::Cursor::~Cursor |
( |
| ) |
|
|
inlinevirtual |
Destructor.
Definition at line 92 of file cursor.h.
Member Function Documentation
void FIFE::Cursor::draw |
( |
| ) |
|
|
virtual |
unsigned int FIFE::Cursor::getDragId |
( |
| ) |
const |
|
inline |
Gets the current mouse cursor pool id
Definition at line 127 of file cursor.h.
Gets the current mouse cursor type
Definition at line 123 of file cursor.h.
unsigned int FIFE::Cursor::getId |
( |
| ) |
const |
|
inline |
Gets the current mouse cursor pool id
Definition at line 119 of file cursor.h.
unsigned int FIFE::Cursor::getNativeId |
( |
unsigned int |
cursor_id | ) |
|
|
protected |
To get some consistancy between platforms, this function checks if cursor_id matches any of the values in NativeCursor, and returns the resource ID specific to the running platform. If no match is found, cursor_id is returned.
- Parameters:
-
One | of the values in NativeCursor |
Definition at line 188 of file cursor.cpp.
Referenced by setNativeCursor().
Gets the current mouse cursor type
Definition at line 115 of file cursor.h.
unsigned int FIFE::Cursor::getX |
( |
| ) |
const |
|
inline |
Gets the current mouse x position
Definition at line 131 of file cursor.h.
unsigned int FIFE::Cursor::getY |
( |
| ) |
const |
|
inline |
Gets the current mouse y position
Definition at line 135 of file cursor.h.
void FIFE::Cursor::set |
( |
MouseCursorType |
ctype, |
|
|
unsigned int |
cursor_id = 0 |
|
) |
| |
Sets the current mouse cursor type and possible pool value
- Parameters:
-
ctype | cursor type |
cursor_id | Pool id to image or animation. For native cursors, this is the resource id to native cursor, or one of the values in NativeCursor |
Definition at line 98 of file cursor.cpp.
References FIFE::TimeManager::getTime(), and setNativeCursor().
void FIFE::Cursor::setDrag |
( |
MouseCursorType |
ctype, |
|
|
unsigned int |
drag_id = 0 , |
|
|
int |
drag_offset_x = 0 , |
|
|
int |
drag_offset_y = 0 |
|
) |
| |
Sets the current drag cursor type and pool value
- Parameters:
-
ctype | drag cursor type |
drag_id | pool id for the drag cursor (either image or animation) |
drag_offset | offset of drag image shown with cursor |
Definition at line 122 of file cursor.cpp.
References FIFE::TimeManager::getTime().
void FIFE::Cursor::setNativeCursor |
( |
unsigned int |
cursor_id | ) |
|
|
protected |
Sets the cursor to a native type.
- Parameters:
-
cursor_id | Resource id to native cursor, or one of the values in NativeCursor |
Definition at line 276 of file cursor.cpp.
References getNativeId().
Referenced by set().
The documentation for this class was generated from the following files: