backends: Fetch libwacom information for tablets in MetaInputSettings

Given that information defines largely how such devices are to be
configured, it makes sense to have that information at hand. A getter
has been also added for the places where it could be useful, although
it will require HAVE_LIBWACOM checks in callers too.
This commit is contained in:
Carlos Garnacho
2016-05-13 13:20:07 +02:00
parent f3b94d9a78
commit 77b33a86b8
2 changed files with 69 additions and 0 deletions

View File

@ -27,6 +27,10 @@
#include <clutter/clutter.h>
#ifdef HAVE_LIBWACOM
#include <libwacom/libwacom.h>
#endif
#define META_TYPE_INPUT_SETTINGS (meta_input_settings_get_type ())
#define META_INPUT_SETTINGS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), META_TYPE_INPUT_SETTINGS, MetaInputSettings))
#define META_INPUT_SETTINGS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), META_TYPE_INPUT_SETTINGS, MetaInputSettingsClass))
@ -102,4 +106,9 @@ MetaInputSettings * meta_input_settings_create (void);
GDesktopTabletMapping meta_input_settings_get_tablet_mapping (MetaInputSettings *settings,
ClutterInputDevice *device);
#ifdef HAVE_LIBWACOM
WacomDevice * meta_input_settings_get_tablet_wacom_device (MetaInputSettings *settings,
ClutterInputDevice *device);
#endif
#endif /* META_INPUT_SETTINGS_PRIVATE_H */