|
TachyonUI 0.1.0
High-performance UI for building tools.
|
Persistent drag state; one drag at a time application-wide. More...
#include <gui_controls/subsystems/gui_reorderable_subsystem.h>
Public Member Functions | |
| bool | IsPressed () const |
| An item is pressed (maybe not yet dragged). | |
| bool | IsDragging () const |
| An item is pressed and has moved the drag distance. | |
| tachyon::int2 | Offset () const |
| The pointer's travel since the press, layout space. | |
Public Attributes | |
| PointerDrag | press |
| the item's press; a drag once it moves the drag distance | |
| tachyon::int2 | cursorLocal {} |
| latest pointer, layout space (like originalRects, groupRect) | |
| tachyon::int2 | cursorScreen {} |
| latest pointer, screen pixels | |
| bool | isWrapped = false |
| the group wraps its items onto several lines | |
| tachyon::ID | groupID = tachyon::ID::Invalid() |
| int | draggedIndex = -1 |
| slot the item was dragged from | |
| int | insertionIndex = -1 |
| slot it would drop into | |
| int | itemCount = 0 |
| the group's items, the slots (other children aren't) | |
| std::vector< tachyon::IntRect > | originalRects |
| item rects at drag start, layout space | |
| std::vector< tachyon::ID > | originalIDs |
| Child IDs at drag start, in slot order, so MouseUp can resolve slots by ID (storage is already visually reordered by then). | |
| ReorderDirection | direction = ReorderDirection::Vertical |
| tachyon::IntRect | groupRect {} |
| group bounds at drag start, layout space | |
Persistent drag state; one drag at a time application-wide.
|
inline |
An item is pressed (maybe not yet dragged).
|
inline |
An item is pressed and has moved the drag distance.
|
inline |
The pointer's travel since the press, layout space.
| PointerDrag tachyon::ReorderableDragState::press |
the item's press; a drag once it moves the drag distance
| tachyon::int2 tachyon::ReorderableDragState::cursorLocal {} |
latest pointer, layout space (like originalRects, groupRect)
| tachyon::int2 tachyon::ReorderableDragState::cursorScreen {} |
latest pointer, screen pixels
| bool tachyon::ReorderableDragState::isWrapped = false |
the group wraps its items onto several lines
| tachyon::ID tachyon::ReorderableDragState::groupID = tachyon::ID::Invalid() |
| int tachyon::ReorderableDragState::draggedIndex = -1 |
slot the item was dragged from
| int tachyon::ReorderableDragState::insertionIndex = -1 |
slot it would drop into
| int tachyon::ReorderableDragState::itemCount = 0 |
the group's items, the slots (other children aren't)
| std::vector<tachyon::IntRect> tachyon::ReorderableDragState::originalRects |
item rects at drag start, layout space
| std::vector<tachyon::ID> tachyon::ReorderableDragState::originalIDs |
Child IDs at drag start, in slot order, so MouseUp can resolve slots by ID (storage is already visually reordered by then).
| ReorderDirection tachyon::ReorderableDragState::direction = ReorderDirection::Vertical |
| tachyon::IntRect tachyon::ReorderableDragState::groupRect {} |
group bounds at drag start, layout space