August'24: Kamaelia is in maintenance mode and will recieve periodic updates, about twice a year, primarily targeted around Python 3 and ecosystem compatibility. PRs are always welcome. Latest Release: 1.14.32 (2024/3/24)
A subclass of Kamaelia.UI.MH.DragHandler that implements "click and hold" dragging of particles for the TopologyViewer.
See source for TopologyViewer.
This is an implementation of Kamaelia.UI.MH.DragHandler. See that for more details.
The detect() method uses the withinRadius method of the physics attribute of the 'app' to determine which (if any) particle the mouse is hovering over when the drag is started. If there is no particle, then the drag does not begin.
At the start of the drag, the particle is 'frozen' to prevent motion due to the physics model of the topology viewer. This is achieved by calling the freeze() and unfreeze() methods of the particle. The particle is also 'selected'.
During the drag the particle's coordinates are updated and the physics model is notified of the change.
Got a problem with the documentation? Something unclear that could be clearer? Want to help improve it? Constructive criticism is very welcome - especially if you can suggest a better rewording!
Please leave you feedback here in reply to the documentation thread in the Kamaelia blog.
-- Automatic documentation generator, 05 Jun 2009 at 03:01:38 UTC/GMT