49 Vec2 startPos()
const;
59 Down(MouseInfo::Impl&,
Vec2 objectPos);
62 Down& operator=(const
Down&) = delete;
80 explicit Over(MouseInfo::Impl&);
83 MouseInfo::Impl& parent;
90 friend class jngl::Window;
94 void setMousePos(
Vec2);
Contains jngl::Vec2 class.
std::span< Over > cursors()
Only returns mouse cursors that are currently not over something.
void transform(const jngl::Mat3 &transformationMatrix)
Applies the transformationMatrix on the mouse position.
MouseInfo & input()
Returns a reference to the global MouseInfo instance, similar to jngl::modelview()
Vec2 newPos() const
returns nullopt when the mouse has been released
bool pressedAgain() const
if you keep this object alive after released() returned true, this will return true again if the mous...
void blockPressedImmediately()
Calling this will cause pressedAgain() to return false directly, not waiting for the next frame or an...
std::optional< Down > pressed(Vec2 objectPos)
calling this will result in all future calls of MouseInfo::cursors not returning this cursor