mirror of
https://github.com/love2d/love.git
synced 2026-08-18 03:34:23 +02:00
Added love.mouse.hasCursor. Returns true if mouse cursors are available.
--HG-- branch : minor
This commit is contained in:
@@ -112,6 +112,12 @@ love::mouse::Cursor *Mouse::getCursor() const
|
||||
return curCursor.get();
|
||||
}
|
||||
|
||||
|
||||
bool Mouse::hasCursor() const
|
||||
{
|
||||
return SDL_GetDefaultCursor() != nullptr;
|
||||
}
|
||||
|
||||
int Mouse::getX() const
|
||||
{
|
||||
int x;
|
||||
|
||||
@@ -53,6 +53,8 @@ public:
|
||||
|
||||
love::mouse::Cursor *getCursor() const;
|
||||
|
||||
bool hasCursor() const;
|
||||
|
||||
int getX() const;
|
||||
int getY() const;
|
||||
void getPosition(int &x, int &y) const;
|
||||
|
||||
Reference in New Issue
Block a user