[gtk/device-cleanup: 3/4] gdk: Drop gdk_device_set_axis_use
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/device-cleanup: 3/4] gdk: Drop gdk_device_set_axis_use
- Date: Tue, 9 Jun 2020 19:30:52 +0000 (UTC)
commit 54c098761f99e80ae6de119937ffe70d892714e4
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Jun 9 15:15:51 2020 -0400
gdk: Drop gdk_device_set_axis_use
If you need some axes changed, you can just flip
the values when you receive them.
docs/reference/gdk/gdk4-sections.txt | 1 -
gdk/gdkdevice.c | 41 ------------------------------------
gdk/gdkdevice.h | 4 ----
3 files changed, 46 deletions(-)
---
diff --git a/docs/reference/gdk/gdk4-sections.txt b/docs/reference/gdk/gdk4-sections.txt
index cb235271a8..6834b99d93 100644
--- a/docs/reference/gdk/gdk4-sections.txt
+++ b/docs/reference/gdk/gdk4-sections.txt
@@ -357,7 +357,6 @@ gdk_device_get_name
gdk_device_get_vendor_id
gdk_device_get_product_id
gdk_device_get_source
-gdk_device_set_axis_use
gdk_device_get_axis_use
gdk_device_get_associated_device
gdk_device_list_slave_devices
diff --git a/gdk/gdkdevice.c b/gdk/gdkdevice.c
index 6201631b07..a6c8347f91 100644
--- a/gdk/gdkdevice.c
+++ b/gdk/gdkdevice.c
@@ -707,47 +707,6 @@ gdk_device_get_axis_use (GdkDevice *device,
return info->use;
}
-/**
- * gdk_device_set_axis_use:
- * @device: a pointer #GdkDevice
- * @index_: the index of the axis
- * @use: specifies how the axis is used
- *
- * Specifies how an axis of a device is used.
- **/
-void
-gdk_device_set_axis_use (GdkDevice *device,
- guint index_,
- GdkAxisUse use)
-{
- GdkAxisInfo *info;
-
- g_return_if_fail (GDK_IS_DEVICE (device));
- g_return_if_fail (device->source != GDK_SOURCE_KEYBOARD);
- g_return_if_fail (index_ < device->axes->len);
-
- info = &g_array_index (device->axes, GdkAxisInfo, index_);
- info->use = use;
-
- switch ((guint) use)
- {
- case GDK_AXIS_X:
- case GDK_AXIS_Y:
- info->min_axis = 0;
- info->max_axis = 0;
- break;
- case GDK_AXIS_XTILT:
- case GDK_AXIS_YTILT:
- info->min_axis = -1;
- info->max_axis = 1;
- break;
- default:
- info->min_axis = 0;
- info->max_axis = 1;
- break;
- }
-}
-
/**
* gdk_device_get_display:
* @device: a #GdkDevice
diff --git a/gdk/gdkdevice.h b/gdk/gdkdevice.h
index 7f7aea3bfe..56b76d49a0 100644
--- a/gdk/gdkdevice.h
+++ b/gdk/gdkdevice.h
@@ -118,10 +118,6 @@ GdkInputSource gdk_device_get_source (GdkDevice *device);
GDK_AVAILABLE_IN_ALL
GdkAxisUse gdk_device_get_axis_use (GdkDevice *device,
guint index_);
-GDK_AVAILABLE_IN_ALL
-void gdk_device_set_axis_use (GdkDevice *device,
- guint index_,
- GdkAxisUse use);
GDK_AVAILABLE_IN_ALL
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]