void recursivelyHandleMagnify(final MagnificationEvent e) { for (final MagnificationListener listener : handler.magnifiers) { listener.magnify(e); if (e.isConsumed()) return; } final PerComponentNotifier next = getNextNotifierForComponent(component.getParent()); if (next != null) next.recursivelyHandleMagnify(e); }
void recursivelyHandlePressure(final PressureEvent e) { for (final PressureListener listener : handler.pressures) { listener.pressure(e); if (e.isConsumed()) return; } final PerComponentNotifier next = getNextNotifierForComponent(component.getParent()); if (next != null) next.recursivelyHandlePressure(e); }
void recursivelyHandleSwipe(final double x, final double y, final SwipeEvent e) { for (final SwipeListener listener : handler.swipers) { if (x < 0) listener.swipedLeft(e); if (x > 0) listener.swipedRight(e); if (y < 0) listener.swipedDown(e); if (y > 0) listener.swipedUp(e); if (e.isConsumed()) return; } final PerComponentNotifier next = getNextNotifierForComponent(component.getParent()); if (next != null) next.recursivelyHandleSwipe(x, y, e); }
void recursivelyHandlePhaseChange(final double phase, final GesturePhaseEvent e) { for (final GesturePhaseListener listener : handler.phasers) { if (phase < 0) { listener.gestureBegan(e); } else { listener.gestureEnded(e); } if (e.isConsumed()) return; } final PerComponentNotifier next = getNextNotifierForComponent(component.getParent()); if (next != null) next.recursivelyHandlePhaseChange(phase, e); }