DVUI

dragStart

Parameters

#
self:*TreeWidget
*TreeWidget
branch_id:usize
usize
p:dvui.Point.Physical
dvui.Point.Physical

Source

Implementation

#
pub fn dragStart(self: *TreeWidget, branch_id: usize, p: dvui.Point.Physical) void {
    self.id_branch = branch_id;
    self.drag_point = p;
    dvui.captureMouse(self.data(), 0);
    if (self.init_options.drag_name) |dn| {
        // have to call dragStart to set the drag name
        dvui.dragStart(.left, p, .{ .name = dn });
        dvui.captureMouse(null, 0);
    }
}