DragSession

One drag stroke on a number: press, move with cursor wrap, release.

Declared in src/libs/libwidgets/components/DragSession.hpp
Group libwidgets

Detailed description

Taken out of DragNumber so that a widget and an item delegate drive a number the same way (config-ui §CFGV-5c). The math is the pure dragmotor namespace. This class adds the stroke: the press position, the cursor wrap that keeps the pointer from reaching a screen edge, and the release that puts the cursor back.

The cursor is grabbed by the caller, because a widget grabs the mouse and a view grabs it on its viewport.

In this section