Last updated at 3:06 pm UTC on 20 September 2020
ActiveHand is a global variable set to the active HandMorph of the current World. It is one of three globals that were introduced in Squeak 3.10.2 in ActiveGlobals.
ActiveHand is used in the method #doOneCycleNowFor: of WorldState.
"Immediately do one cycle of the interaction loop.
This should not be called directly, but only via doOneCycleFor:"
| capturingGesture |
capturingGesture := false.
"self flag: #bob. " "need to consider remote hands in lower worlds"
"process user input events"
LastCycleTime := Time millisecondClockValue.
self handsDo: [:h |
ActiveHand := h.
capturingGesture := capturingGesture or: [ h isCapturingGesturePoints ].
ActiveHand := nil
"the default is the primary hand"
ActiveHand := self hands first.
"The gesture recognizer needs enough points to be accurate.
Therefore morph stepping is disabled while capturing points for the recognizer"
[aWorld runStepMethods. "there are currently some variations here"
self displayWorldSafely: aWorld].
More see: ActiveHand method processEvents