2016-10-31 17:05:23 +00:00
|
|
|
/*
|
|
|
|
* Copyright © 2016 Red Hat
|
|
|
|
*
|
|
|
|
* 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 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, see <http://www.gnu.org/licenses/>.
|
|
|
|
*
|
|
|
|
* Author: Carlos Garnacho <carlosg@gnome.org>
|
|
|
|
*/
|
|
|
|
|
2019-03-22 12:53:00 +00:00
|
|
|
#include "config.h"
|
2016-10-31 17:05:23 +00:00
|
|
|
|
2019-03-22 12:53:00 +00:00
|
|
|
#include "meta-input-device-tool-x11.h"
|
2016-10-31 17:05:23 +00:00
|
|
|
|
2019-03-22 12:53:00 +00:00
|
|
|
G_DEFINE_TYPE (MetaInputDeviceToolX11, meta_input_device_tool_x11,
|
2016-10-31 17:05:23 +00:00
|
|
|
CLUTTER_TYPE_INPUT_DEVICE_TOOL)
|
|
|
|
|
|
|
|
static void
|
2019-03-22 12:53:00 +00:00
|
|
|
meta_input_device_tool_x11_class_init (MetaInputDeviceToolX11Class *klass)
|
2016-10-31 17:05:23 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
2019-03-22 12:53:00 +00:00
|
|
|
meta_input_device_tool_x11_init (MetaInputDeviceToolX11 *tool)
|
2016-10-31 17:05:23 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
ClutterInputDeviceTool *
|
2019-03-22 12:53:00 +00:00
|
|
|
meta_input_device_tool_x11_new (guint serial,
|
|
|
|
ClutterInputDeviceToolType type)
|
2016-10-31 17:05:23 +00:00
|
|
|
{
|
2020-11-18 23:47:04 +00:00
|
|
|
ClutterInputAxisFlags axes =
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_PRESSURE |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_DISTANCE |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_XTILT |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_YTILT |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_WHEEL |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_DISTANCE |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_ROTATION |
|
|
|
|
CLUTTER_INPUT_AXIS_FLAG_SLIDER;
|
|
|
|
|
2019-03-22 12:53:00 +00:00
|
|
|
return g_object_new (META_TYPE_INPUT_DEVICE_TOOL_X11,
|
2016-10-31 17:05:23 +00:00
|
|
|
"type", type,
|
|
|
|
"serial", serial,
|
2020-11-18 23:47:04 +00:00
|
|
|
"axes", axes,
|
2016-10-31 17:05:23 +00:00
|
|
|
NULL);
|
|
|
|
}
|