mirror of
https://github.com/brl/mutter.git
synced 2025-06-13 16:59:30 +00:00
clutter: Drop ClutterInputDevice private tool maintenance API
This is just used in the native backend (with the X11 going its own way). Just keep a HT of tools there, and drop this API. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
This commit is contained in:

committed by
Marge Bot

parent
06d577fdf3
commit
c7f989c1e2
@ -92,8 +92,6 @@ struct _ClutterInputDevice
|
||||
char *product_id;
|
||||
char *node_path;
|
||||
|
||||
GPtrArray *tools;
|
||||
|
||||
int n_rings;
|
||||
int n_strips;
|
||||
int n_mode_groups;
|
||||
@ -116,16 +114,6 @@ CLUTTER_EXPORT
|
||||
void _clutter_input_device_remove_event_sequence (ClutterInputDevice *device,
|
||||
ClutterEvent *event);
|
||||
|
||||
CLUTTER_EXPORT
|
||||
void clutter_input_device_add_tool (ClutterInputDevice *device,
|
||||
ClutterInputDeviceTool *tool);
|
||||
|
||||
CLUTTER_EXPORT
|
||||
ClutterInputDeviceTool *
|
||||
clutter_input_device_lookup_tool (ClutterInputDevice *device,
|
||||
guint64 serial,
|
||||
ClutterInputDeviceToolType type);
|
||||
|
||||
CLUTTER_EXPORT
|
||||
gboolean clutter_input_device_keycode_to_evdev (ClutterInputDevice *device,
|
||||
guint hardware_keycode,
|
||||
|
@ -1172,46 +1172,6 @@ clutter_input_device_get_product_id (ClutterInputDevice *device)
|
||||
return device->product_id;
|
||||
}
|
||||
|
||||
void
|
||||
clutter_input_device_add_tool (ClutterInputDevice *device,
|
||||
ClutterInputDeviceTool *tool)
|
||||
{
|
||||
g_return_if_fail (CLUTTER_IS_INPUT_DEVICE (device));
|
||||
g_return_if_fail (clutter_input_device_get_device_mode (device) != CLUTTER_INPUT_MODE_LOGICAL);
|
||||
g_return_if_fail (CLUTTER_IS_INPUT_DEVICE_TOOL (tool));
|
||||
|
||||
if (!device->tools)
|
||||
device->tools = g_ptr_array_new_with_free_func ((GDestroyNotify) g_object_unref);
|
||||
|
||||
g_ptr_array_add (device->tools, tool);
|
||||
}
|
||||
|
||||
ClutterInputDeviceTool *
|
||||
clutter_input_device_lookup_tool (ClutterInputDevice *device,
|
||||
guint64 serial,
|
||||
ClutterInputDeviceToolType type)
|
||||
{
|
||||
ClutterInputDeviceTool *tool;
|
||||
guint i;
|
||||
|
||||
g_return_val_if_fail (CLUTTER_IS_INPUT_DEVICE (device), NULL);
|
||||
g_return_val_if_fail (clutter_input_device_get_device_mode (device) != CLUTTER_INPUT_MODE_LOGICAL, NULL);
|
||||
|
||||
if (!device->tools)
|
||||
return NULL;
|
||||
|
||||
for (i = 0; i < device->tools->len; i++)
|
||||
{
|
||||
tool = g_ptr_array_index (device->tools, i);
|
||||
|
||||
if (serial == clutter_input_device_tool_get_serial (tool) &&
|
||||
type == clutter_input_device_tool_get_tool_type (tool))
|
||||
return tool;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
gint
|
||||
clutter_input_device_get_n_rings (ClutterInputDevice *device)
|
||||
{
|
||||
|
Reference in New Issue
Block a user