VCV Rack API v2
Loading...
Searching...
No Matches
rack::widget::Widget::DragHoverEvent Struct Reference

Occurs every frame when the mouse is hovering over a Widget while another Widget (possibly the same one) is being dragged. More...

#include <Widget.hpp>

Inheritance diagram for rack::widget::Widget::DragHoverEvent:
[legend]
Collaboration diagram for rack::widget::Widget::DragHoverEvent:
[legend]

Public Attributes

Widgetorigin = NULL
 The dragged widget.
 
math::Vec mouseDelta
 Change in mouse position since the last frame.
 
- Public Attributes inherited from rack::widget::Widget::DragBaseEvent
int button
 The mouse button held while dragging.
 
- Public Attributes inherited from rack::widget::BaseEvent
EventContextcontext = NULL
 
- Public Attributes inherited from rack::widget::Widget::PositionBaseEvent
math::Vec pos
 The pixel coordinate where the event occurred, relative to the Widget it is called on.
 

Additional Inherited Members

- Public Member Functions inherited from rack::widget::BaseEvent
void stopPropagating () const
 Prevents the event from being handled by more Widgets.
 
bool isPropagating () const
 
void setTarget (Widget *w) const
 Tells the event handler that a particular Widget consumed the event.
 
WidgetgetTarget () const
 
void consume (Widget *w) const
 Sets the target Widget and stops propagating.
 
void unconsume () const
 
bool isConsumed () const
 

Detailed Description

Occurs every frame when the mouse is hovering over a Widget while another Widget (possibly the same one) is being dragged.

Recurses. Consume this event to allow DragEnter and DragLeave to occur.

Member Data Documentation

◆ origin

Widget* rack::widget::Widget::DragHoverEvent::origin = NULL

The dragged widget.

◆ mouseDelta

math::Vec rack::widget::Widget::DragHoverEvent::mouseDelta

Change in mouse position since the last frame.

Can be zero.


The documentation for this struct was generated from the following file: