46 jassert (image.getScaledBounds().toNearestInt().contains (
hotSpot));
61 if (
auto strong = weak.lock())
64 auto strong = std::make_shared<SharedCursorHandle> (type);
71 return type == standardType && standard;
121 return getHandle() ==
other.getHandle();
126 return cursorHandle !=
nullptr ? cursorHandle->isStandardType (type)
127 : (type == NormalCursor);
145 return cursorHandle !=
nullptr ? cursorHandle->getHandle() :
nullptr;
148void MouseCursor::showInWindow (ComponentPeer* peer)
const
150 PlatformSpecificHandle::showInWindow (getHandle(), peer);
MouseInputSource getMainMouseSource() const noexcept
Returns the main mouse input device that the system is using.
static Desktop &JUCE_CALLTYPE getInstance()
There's only one desktop object, and this method will return it.
Automatically locks and unlocks a mutex object.
Holds a fixed-size bitmap.
Represents a mouse cursor image.
bool operator!=(const MouseCursor &) const noexcept
Checks whether two mouse cursors are the same.
static void hideWaitCursor()
If showWaitCursor has been called, this will return the mouse to its normal state.
bool operator==(const MouseCursor &) const noexcept
Checks whether two mouse cursors are the same.
~MouseCursor()
Destructor.
static void showWaitCursor()
Makes the system show its default 'busy' cursor.
MouseCursor() noexcept
Creates the standard arrow cursor.
StandardCursorType
The set of available standard mouse cursors.
@ NormalCursor
The standard arrow cursor.
@ WaitCursor
The normal hourglass or spinning-beachball 'busy' cursor.
MouseCursor & operator=(const MouseCursor &)
Copies this cursor from another object.
A pair of (x, y) coordinates.
An image that will be resampled before it is drawn.
A simple spin-lock class that can be used as a simple, low-overhead mutex for uncontended situations.
Type unalignedPointerCast(void *ptr) noexcept
Casts a pointer to another type via void*, which suppresses the cast-align warning which sometimes ar...
bool isPositiveAndBelow(Type1 valueToTest, Type2 upperLimit) noexcept
Returns true if a value is at least zero, and also below a specified upper limit.