summaryrefslogtreecommitdiff
path: root/atspi/atspi-device-legacy.h
diff options
context:
space:
mode:
authorMike Gorse <mgorse@suse.com>2021-01-11 13:32:06 -0600
committerMike Gorse <mgorse@suse.com>2021-01-11 13:32:06 -0600
commit7bd1ad706c92a9342e5078238ce4380e544aa967 (patch)
treef09ab765bb97dbcdd0cba047254768da7614eb02 /atspi/atspi-device-legacy.h
parentbefced84236ec782d3a41d8cc06ceb3fdb61ae75 (diff)
downloadat-spi2-core-7bd1ad706c92a9342e5078238ce4380e544aa967.tar.gz
Add device API
This is intended to replace the registry-based method for capturing keystrokes. It is needed because gtk 4 no longer sends key notifications in a way that atk-bridge can process them. Unlike the original API, key grabs are separated from key notifications. Clients wishing to consume keystrokes must proactively register a grab for the given key. Currently, there is a backend for X11 and an unfinished legacy back end using the old registry-based method. Hopefully, there will be a mutter/wayland back end in the future, but we need to define a protocol there first.
Diffstat (limited to 'atspi/atspi-device-legacy.h')
-rw-r--r--atspi/atspi-device-legacy.h59
1 files changed, 59 insertions, 0 deletions
diff --git a/atspi/atspi-device-legacy.h b/atspi/atspi-device-legacy.h
new file mode 100644
index 00000000..50f777e2
--- /dev/null
+++ b/atspi/atspi-device-legacy.h
@@ -0,0 +1,59 @@
+/*
+ * AT-SPI - Assistive Technology Service Provider Interface
+ * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
+ *
+ * Copyright 2020 SUSE LLC.
+ *
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#ifndef _ATSPI_DEVICE_LEGACY_H_
+#define _ATSPI_DEVICE_LEGACY_H_
+
+#include "glib-object.h"
+
+#include "atspi-types.h"
+#include "atspi-device.h"
+
+G_BEGIN_DECLS
+
+#define ATSPI_TYPE_DEVICE_LEGACY (atspi_device_legacy_get_type ())
+#define ATSPI_DEVICE_LEGACY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATSPI_TYPE_DEVICE_LEGACY, AtspiDeviceLegacy))
+#define ATSPI_DEVICE_LEGACY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATSPI_TYPE_DEVICE_LEGACY, AtspiDeviceLegacyClass))
+#define ATSPI_IS_DEVICE_LEGACY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATSPI_TYPE_DEVICE_LEGACY))
+#define ATSPI_IS_DEVICE_LEGACY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATSPI_TYPE_DEVICE_LEGACY))
+#define ATSPI_DEVICE_LEGACY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATSPI_TYPE_DEVICE_LEGACY, AtspiDeviceLegacyClass))
+
+typedef struct _AtspiDeviceLegacy AtspiDeviceLegacy;
+struct _AtspiDeviceLegacy
+{
+ AtspiDevice parent;
+};
+
+typedef struct _AtspiDeviceLegacyClass AtspiDeviceLegacyClass;
+struct _AtspiDeviceLegacyClass
+{
+ AtspiDeviceClass parent_class;
+};
+
+GType atspi_device_legacy_get_type (void);
+
+AtspiDeviceLegacy *atspi_device_legacy_new ();
+
+G_END_DECLS
+
+#endif /* _ATSPI_DEVICE_LEGACY_H_ */