Next: , Previous: ClutterFlowLayout, Up: Top


37 ClutterGestureAction

Action for gesture gestures

37.1 Overview

<clutter-gesture-action> is a sub-class of <clutter-action> that implements the logic for recognizing gesture gestures. It listens for low level events such as <clutter-button-event> and <clutter-motion-event> on the stage to raise the <"gesture-begin">, <"gesture-progress">, and * <"gesture-end"> signals.

To use <clutter-gesture-action> you just need to apply it to a <clutter-actor> using clutter-actor-add-action and connect to the signals:

     
       ClutterAction *action = clutter_gesture_action_new ();
     
       clutter_actor_add_action (actor, action);
     
       g_signal_connect (action, "gesture-begin", G_CALLBACK (on_gesture_begin), NULL);
       g_signal_connect (action, "gesture-progress", G_CALLBACK (on_gesture_progress), NULL);
       g_signal_connect (action, "gesture-end", G_CALLBACK (on_gesture_end), NULL);

37.2 Usage

— Function: clutter-gesture-action-new ⇒  (ret <clutter-action>)

Creates a new <clutter-gesture-action> instance.

ret
the newly created <clutter-gesture-action>

Since 1.8