ClutterTapAction

ClutterTapAction — Action for tap gestures

Functions

Signals

void tap Run Last

Types and Values

Object Hierarchy

    GObject
    ╰── GInitiallyUnowned
        ╰── ClutterActorMeta
            ╰── ClutterAction
                ╰── ClutterGestureAction
                    ╰── ClutterTapAction

Description

ClutterTapAction is a sub-class of ClutterGestureAction that implements the logic for recognizing mouse clicks and touch tap gestures.

The simplest usage of ClutterTapAction consists in adding it to a ClutterActor, setting it as reactive and connecting a callback for the “tap” signal, along the lines of the following code:

1
2
3
clutter_actor_add_action (actor, clutter_tap_action_new ());
clutter_actor_set_reactive (actor, TRUE);
g_signal_connect (action, "tap", G_CALLBACK (on_tap_callback), NULL);

Functions

clutter_tap_action_new ()

ClutterAction *
clutter_tap_action_new (void);

Creates a new ClutterTapAction instance

Returns

the newly created ClutterTapAction

Since: 1.14

Types and Values

struct ClutterTapAction

struct ClutterTapAction;

The ClutterTapAction structure contains only private data and should be accessed using the provided API

Since: 1.14


struct ClutterTapActionClass

struct ClutterTapActionClass {
  gboolean (* tap)               (ClutterTapAction    *action,
                                  ClutterActor        *actor);
};

The ClutterTapActionClass structure contains only private data.

Members

tap ()

class handler for the “tap” signal

 

Signal Details

The “tap” signal

void
user_function (ClutterTapAction *action,
               ClutterActor     *actor,
               gpointer          user_data)

The ::tap signal is emitted when the tap gesture is complete.

Parameters

action

the ClutterTapAction that emitted the signal

 

actor

the ClutterActor attached to the action

 

user_data

user data set when the signal handler was connected.

 

Flags: Run Last

Since: 1.14