clutter: Add ClutterDeviceManager::tool-changed signal

This signal will notify whenever a device changed tool.

https://bugzilla.gnome.org/show_bug.cgi?id=773779
This commit is contained in:
Carlos Garnacho 2016-10-31 17:35:01 +01:00
parent cea7d629d9
commit bd83873a7f
2 changed files with 13 additions and 0 deletions

View File

@ -48,6 +48,7 @@
#include "clutter-private.h"
#include "clutter-stage-private.h"
#include "clutter-virtual-input-device.h"
#include "clutter-input-device-tool.h"
struct _ClutterDeviceManagerPrivate
{
@ -70,6 +71,7 @@ enum
{
DEVICE_ADDED,
DEVICE_REMOVED,
TOOL_CHANGED,
LAST_SIGNAL
};
@ -184,6 +186,16 @@ clutter_device_manager_class_init (ClutterDeviceManagerClass *klass)
_clutter_marshal_VOID__OBJECT,
G_TYPE_NONE, 1,
CLUTTER_TYPE_INPUT_DEVICE);
manager_signals[TOOL_CHANGED] =
g_signal_new (I_("tool-changed"),
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
0, NULL, NULL,
_clutter_marshal_VOID__OBJECT_OBJECT,
G_TYPE_NONE, 2,
CLUTTER_TYPE_INPUT_DEVICE,
CLUTTER_TYPE_INPUT_DEVICE_TOOL);
}
static void

View File

@ -23,6 +23,7 @@ VOID:OBJECT
VOID:OBJECT,FLAGS
VOID:OBJECT,FLOAT,FLOAT
VOID:OBJECT,FLOAT,FLOAT,FLAGS
VOID:OBJECT,OBJECT
VOID:OBJECT,PARAM
VOID:OBJECT,POINTER
VOID:OBJECT,UINT