1
0
Fork 0
Commit graph

55 commits

Author SHA1 Message Date
Ivan Molodetskikh
bcf6ee5e55 Name unnamed sources
These names show up in GLib traces in sysprof, so let's make sure they
exist.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1928>
2022-03-04 10:10:05 +03:00
Konstantin Kharlamov
338eea7a37 backends/native/meta-seat: Sync keyboard LEDs when changing layout
Fixes: https://gitlab.gnome.org/GNOME/mutter/-/issues/633
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2279>
2022-02-10 08:11:56 +00:00
Carlos Garnacho
70e44c281c backends/native: Ensure pointer is onscreen in input thread
It's slightly racy to have the main thread update the views and warp
the pointer, since the input thread may not be aware yet of the new
viewport layout.

Make the input thread clamp the pointer so it remains onscreen
instead, when the new viewports are obtained.

Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/64
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2237>
2022-01-16 18:38:20 +00:00
José Expósito
2e8aef6f8a backends/native: Refactor LIBINPUT_EVENT_POINTER_AXIS handling
Move the logic to handle LIBINPUT_EVENT_POINTER_AXIS events to its own
function (handle_pointer_scroll).

Refactor, no functional changes.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1966>
2021-12-14 15:44:48 +00:00
JoseExposito
d4ba16252b backends/native/meta-seat: Capture hold events
Receive hold gesture events from libinput and enqueue them as Clutter
events.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1830>
2021-12-02 20:48:24 +00:00
Carlos Garnacho
5785d8cde0 backends/native: Remove unused array definition
This array is a relic from the input code belonging to Clutter,
and is nowadays unused.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1862>
2021-07-16 19:08:06 +02:00
Jonas Ådahl
3c9ab768ec launcher: Remove now unused file management API
The open/close helpers for (maybe) restricted files has been replaced
with MetaDevicePool, so lets remove that functionality from here.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1828>
2021-07-07 21:03:25 +02:00
Jonas Ådahl
7ce266628e seat-impl: Open/close files via device pool
This replaces going through MetaLauncher to open/close restricted files.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1828>
2021-07-07 21:03:25 +02:00
Carlos Garnacho
b4a7f35146 backends/native: Unref/unset key repeat GSource when cleared
This GSource is not being properly unref nor the variable holding it
cleared. This on one hand leaks the GSource memory, on the other hand
may trigger warnings in keyboard_repeat() as the source may be
(reentrantly) cleared, yet we don't exit early as
seat_impl->repeat_source is never NULL.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1839>
2021-04-27 08:37:38 +00:00
Carlos Garnacho
f92232ae4f backends/native: Check whether views are scaled via MetaViewportInfo
The input thread is in deep water doing the meta_is_*() check itself,
as that pokes the MetaMonitorManager managed by the main thread. Use
the getter from the MetaViewportInfo instead.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1793>
2021-04-13 10:32:14 +00:00
Olivier Fourdan
c016437857 backends/native: Sync LEDs when adding new device
Adding new input devices resets the LED state, make sure to restore it
to keep the LED and XKB state consistent.

Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1594
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1662>
2021-03-13 18:34:22 +00:00
Jonas Ådahl
0786f44b0b seat/impl: Make it possible to run without libinput
Add a flag to MetaSeatNative and MetaSeatImpl that tells it not to
attempt to create a libinput context. This is intended to be used when
mutter is to run headless, as in without any input devices other than
virtual ones.

Currently not hooked up.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1698>
2021-03-12 15:09:45 +00:00
Jonas Dreßler
3263084bcf backends/native: Translate right coords when creating motion events
With commit 7d78768809 we switched to
storing pointer coordinates in MetaInputDeviceNative instead of
ClutterInputDevice, and while we had set the coordinates of the
ClutterInputDevice in ClutterStage when queueing an event, we now set
the MetaInputDeviceNative coordinates in new_absolute_motion_event().

Here a small mistake snuck in: new_absolute_motion_event() only
translates the coordinates of the event, but we call
meta_input_device_native_set_coords() using the x and y variables
(which remain untranslated), so now the input device coordinates are no
longer translated.

Fix that by translating the coordinates of the x and y variables in case
we're we handling a tablet/stylus event instead of only translating the
event coordinates.

Fixes https://gitlab.gnome.org/GNOME/mutter/-/issues/1685

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1760>
2021-03-08 15:33:36 +00:00
Jonas Ådahl
ce3fa3938a clutter/keymap: Make caps and num lock state properties
This removes the responsibility of tracking these from the backend to
the base object. The backends are instead responsible for calling the
function to update the values.

For the native backend, it's important that this happens on the correct
thread, so each time either of these states may change, post a idle
callback on the main thread that sets the, at the time of queuing said
callback, up to date state. This means that things on the main thread
will always be able to get a "new enough but not too new" state when
listening on the 'notify::' signals and getting the property value
after.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1739>
2021-03-04 17:39:08 +00:00
Jonas Ådahl
26912523fa native/seat-impl: Add helper for queuing main thread idle callbacks
Make the emit main thread signal use it. Will be used for calling code
on the main thread from the input thread.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1739>
2021-03-04 17:39:08 +00:00
Alexander Mikhaylenko
2a71ca373b clutter: Add API for retrieving gesture unaccelerated deltas
This will be useful for better aligning behavior between scrolling and
swiping for gnome-shell swipe tracker.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1353>
2021-02-27 08:52:00 +00:00
Jonas Ådahl
e6b70f1a2b seat-impl: Dispatch source also when there are already queued events
Libinput will queue a few initial events when a seat is assigned to the
udev backend; a result of it probing udev adding detected devices. For
us to see these events, we need to dispatch libinput before going idle,
as nothing will show up on the libinput file descriptor until something
else (e.g. keyboard event or mouse movement) wakes us up.

Do this by adding a prepare() function to the libinput GSource, that
checks whether there are any events in the queue already, and return
TRUE if so is the case, causing us to dispatch before going fully idle.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1688>
2021-02-23 10:05:32 +00:00
Robert Mader
6eeeffdc68 src: Stop using GSlice
It has been inofficially deprecated for years, is known to cause issues
with valgrind and potentially hides memory corruption.
Lets stop using it.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1512>
2021-02-22 13:52:27 +01:00
Pascal Nowack
c77e943ce2 backends/native: Handle triple resolution mouse wheels better
When a remote desktop user emits a virtual smooth scrolling event, a
smooth scroll event, that is not emulated, is emitted and on occasion
a discrete scroll event, that is emulated, is emitted.
As base for the discrete scrolling event, the smooth scrolling steps
are accumulated.
When the accumulated smooth scrolling steps surpass the
DISCRETE_SCROLL_STEP, the discrete scrolling event is emitted.

Currently, mutter uses for DISCRETE_SCROLL_STEP the value 10, which is
a terrible value to work with, especially for high resolution mouse
wheels.
When a triple resolution mouse wheel is used, each scrolling step will
have the value 3 1/3.
Three of such events won't however surpass the DISCRETE_SCROLL_STEP.

To fix this situation, add DBL_EPSILON to the calculation step, when
checking for the discrete scroll event to ensure that 3 smooth scroll
events, with each having the value 3 1/3, emit a discrete scrolling
event.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1727>
2021-02-17 21:39:03 +01:00
Carlos Garnacho
b2b66aa8c6 backends/native: Disable touch-mode with pointer presence
The original implementation of ::touch-mode tested for keyboard
presence to know whether the OSK and other touch-only features were
enabled.

However that didn't pan out, every webcam, card reader and kitchen
sink like to live a second life as EV_KEY devices. This made the
detection of actual external keyboards a much harder task than it
sounds, and was thus removed in commit f8e2234ce5.

Try a different approach here, and test for pointer devices, it
doesn't matter if internal or external devices, the rationales:

- It is significantly easier to get this right, there's virtually
  no devices with abs/rel axes that don't try to be a real input
  device of some sorts.
- It's not as good as testing for keyboard presence, but it's the
  next best thing. These usually come in pairs, except in weird
  setups.
- It is better than not having anything for a number of situations:
  - Non-convertible laptops with a touchscreen will get touch-mode
    disabled due to touchpad presence (plus keyboard). There's
    been complains about OSK triggering with those.
  - Same for desktop machines with USB touchscreens, the mouse
    (and presumably keyboard) attached would make touch-mode
    get in the middle.
  - Convertible laptops with a broken tablet-mode switch get a
    chance to work on tablet modes that do disable input devices
    (e.g. detachable keyboards, or via firmware)
  - Kiosk machines, tablets, and other devices that have a
    touchscreen but will not regularly have a mouse/keyboard
    will get the touch-mode enabled.

All in all, this seems to cover more situations the way we expect it,
there's only one situation that the OSK would show where it might
not be desirable, and one that might not show when it better should:

- Tablets and kiosk machines that get one keyboard plugged, but not a
  mouse, will still show the OSK, despite being able to type right
  away.
- Convertible laptops with broken/unreliable tablet-mode switch (e.g.
  ignored by the kernel) rely entirely on the device/firmware
  characteristics to work. If after folding into tablet mode the
  touchpad remains active, touch-mode will not turn on.
  Fixing the tablet-mode switch on these devices should be preferred,
  as that'll also make libinput magically disable the touchpad.

The latter can be worked around with the a11y toggle. The former is
merely inconvenient, and nothing prevents the user from plugging a mouse
in addition.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1710>
2021-02-05 16:07:55 +01:00
Jonas Ådahl
e48be709f8 seat-impl: Remove unused udev client instance
No point in having an unused udev client lingering.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1689>
2021-01-28 20:05:23 +00:00
Carlos Garnacho
d43f95703d backends/native: Update keymap state on latched modifier updates
The input thread refactors missed to update the MetaKeymapNative state when
the keys that trigger the latched modifiers are being pressed. Let that happen
here.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1679>
2021-01-21 15:35:06 +01:00
Jonas Ådahl
05765daabf seat/native: Explicitly destroy MetaSeatImpl
We can't post tasks to the input thread when cleaning up the
MetaSeatImpl, as that will make the GTask complain about adding
references to a to be purged object. Avoid this by adding an explicit
meta_seat_impl_destroy() function that handles the destruction of the
MetaSeatImpl properly.

This also does more of the cleanup in the input thread, as that is where
it was managed. Will likely not make a difference as before this
happened after tearing down the thread, but lets tear down things in the
thread they were managed for good measure.

This fixes the last log spew I see right now when terminating mutter.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1670>
2021-01-19 22:54:32 +01:00
Jonas Ådahl
237cdeef4c seat-impl: Destroy libinput objects on input thread on tear down
We didn't tear down the libinput objects in the right thread when
exiting, but did so after the input thread exited.

We also tried to destroy the libinput devices after the libinput context
was destroyed, which isn't allowed.

Fix these two issues by tearing down the libinput objects in a input
thread task that when done exits the input thread. This effectively
"flushes" the input thread tasks while destroying the libinput objects
just before the thread exits.

While it might fine to tear down libinput objects in an arbitrary (main
in this case) thread while making sure nothing pokes at it in parallel
(e.g. the input thread is gone), libinput is by definition single
threaded, and could theoretically make assumptions about this, and we
shouldn't cause any possible surprises here, so make sure to destroy it
all in the right thread.

This fixes an abort() on exit caused by an assert about invalid object
destruction in libinput.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1663>
2021-01-11 17:17:39 +00:00
Jonas Ådahl
3bf1af07ed seat-impl: Fix some variable names
The "seat" usually refers to the ClutterSeat (MetaSeatNative) object,
and "seat_impl" to the MetaSeatImpl object, but there were still a few
places where this wasn't adhered to so fix those.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1663>
2021-01-11 17:17:39 +00:00
Olivier Fourdan
904d7fa798 backends/native: Protect against NULL pointer constraints
To clear a pointer constraint, the Wayland backend passes a NULL
constraint to the native input backend.

The new async API however tries to reference/un-reference the given
object to use it while running in a separate task, which leads to a
warning from GLib trying to g_object_ref()/g_object_unref() a non
GObject pointer.

To avoid that issue, simply set the data only if the given constraints
pointer is not NULL.

Suggested-by: Carlos Garnacho <carlosg@gnome.org>
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1587
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1652>
2020-12-22 14:45:00 +01:00
Carlos Garnacho
b2b3d000d2 backends/native: Dispose the libinput device in the input thread
Currently, the MetaInputDeviceNative owns the libinput_device, with the
small catch that it is eventually finished in the main thread (as the
CLUTTER_DEVICE_REMOVED event keeps the last reference to it).

Make it sure that the libinput_device is destroyed in the input thread,
before giving away the last extra input device references.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1639>
2020-12-16 17:09:58 +01:00
Carlos Garnacho
64d5e8a9bd backends/native: Drop MetaEventNative
This doesn't really hold anything now, so we can stop trying to
copy these across events.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1623>
2020-12-08 15:37:38 +00:00
Carlos Garnacho
b88790554b clutter: Move relative motion information to ClutterEvent
Instead of using native backend platform data specifically, store
this info in ClutterMotionEvent. This includes time in usec since
it's just used for motion events, in the future it could make sense
to make these general to all events again, but it could make sense
to make ClutterEvent structs private before.

In order to express that a motion event has relative motion info,
the CLUTTER_EVENT_FLAG_RELATIVE_MOTION event flag has been added
for it.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1623>
2020-12-08 15:37:38 +00:00
Carlos Garnacho
eaa04ecee5 backends: Unify touch sequence to slot conversion
We had code in both backends that sort of independently associated
sequences to slots. Make both transform slots to sequences the same
way, so they may share the implementation convert those back to slots.

This helper now lives in Clutter API.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1623>
2020-12-08 15:37:38 +00:00
Carlos Garnacho
9f5c453fc7 clutter: Move evdev evcode data to Clutter button/key events
We have this as platform-dependent data in the native backend, and
a bunch of fallback code done in place in the evcode users. Stop
making this platform-dependent data, and move it to the relevant
ClutterEvents.

The fallback code for the X11 backend case is about the same, but
now it is done directly by the X11 backend.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1623>
2020-12-08 15:37:38 +00:00
Carlos Garnacho
13202f4e45 backends/native: Pass xkb_state directly when updating MetaKeymapNative
Figuring out the MetaSeatImpl this much indirectly is fairly awkward when
the keymap is only updated from the MetaSeatImpl, pass instead the seat
impl's xkb_state, as we have it handy in all the places this is called.

This will not break on NULL seats during initialization, should the numlock
state be restored from previous sessions.

Fixes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1556
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1612>
2020-11-27 17:34:55 +00:00
Carlos Garnacho
8b6ea12fac backends/native: Add distinct meta-input-thread.h header
Make it impossible to add individual includes of input thread objects.
This must go through meta-input-thread.h now, which should be enough
to make anyone think it twice.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
c03be03cd3 backends/native: Add a bunch of "_in_impl" suffixes to functions
They're a dime a dozen. If it gets called exclusively from the
input thread, it got one. Hopefully these breadcrumbs will be
enough so people don't lose their way here.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
820262e537 backends/native: Add input thread inside MetaSeatImpl
This (now) doesn't change anything in regards to the API that the UI
thread should access from the MetaSeatImpl. The MetaInputDeviceNative,
MetaInputSettings and MetaKeymap objects are now considered owned by
the input thread, as well as all of libinput objects.

The MetaEventSource now dispatches events in a GMainContext that is
the thread default to this thread, and all UI-thread-accessible API
(seat and virtual input device API) will be handled in a serialized
manner by that same input thread.

The MetaSeatImpl itself is still considered to be owned by the caller
thread, and all the signals that this object emits will be emitted in
the GMainContext that is default at the time of calling
meta_seat_impl_new().

The MetaInputSettings configuration changes will likewise be handled
in the input thread, close to libinput devices.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
2ff5bb4299 backends/native: Update keyboard a11y status in seat impl
Instead of going through the event queue, stage handling code, and
back to the input device via a vmethod call, do this directly in the
MetaSeatImpl. This is not too different from X11, where everything
happens inside the backend.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
ceefa72ade backends/native: Shuffle keyboard a11y signal connection into MetaSeatImpl
This signal gets emitted in the input thread, and does things that
belong to it. Make it clear by moving to the MetaSeatImpl.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
c7f989c1e2 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>
2020-11-27 15:14:34 +00:00
Carlos Garnacho
5689a843c7 clutter: Drop internal update_from_tool() vmethod
This is kinda pointless now, and will be made completely unneeded
by dropping device axes.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
168ceb9905 backends: Forward event axes as array of ClutterInputAxes elements
Instead of encoding arrays in ways that we need the ClutterInputDevice
to decode them, use ClutterInputAxes as the array index.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
be9c531ab9 clutter: Drop clutter_input_device_get_associated_device()
And the private setter. One may ask the seat for the pointer/keyboard
instead of asking the device for its counterpart.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
c4fa5ef88a clutter: Drop clutter_input_device_get_physical_devices() API
This is unused, we have the seat for this kind of stuff.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
fd90e41e12 backends/native: Make some MetaSeatImpl API "async"
This API is the one accessed from different bits of the UI thread,
make it "async" (it's basically one-way setters, so API stays the same
in the surface) and able to run in the MetaSeatImpl main context.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
f7fbd6ea6f backends: Handle numlock saving/restoring directly in backends
Simplify the handling of numlock state, so it can be entirely handled
within the input thread. Since the saving/restoring is triggered inside
each backend code, there's no need anymore for meta_backend_set_numlock().

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
23f95348fd backends/native: Shuffle xkb_keymap creation
Push it a little bit down to the MetaSeatNative. As both the UI thread
and the input thread are interested in dealing with the xkb_keymap and
it is not meant to be used in different threads, keep 2 separate copies
around.

The keyboard map will always be set from the UI thread, so the xkb_keymap
owned by the MetaSeatNative (owned by the UI thread) can be considered
canonical.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
40665b0fb1 backends/native: Seal MetaKeymapNative xkb usage
Don't let the vfuncs (meant to be called from the UI thread) deal with
xkb state itself. Instead store the current state in struct fields, which
is then fetched in vfuncs.

This makes the keymap able to be used from the UI thread, while being
maintained by the input thread. Same caveats apply than
clutter_seat_query_state(), you are asking for the most up-to-date state,
but it still may be changing under your feet.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
cf45050cba backends/native: Surround device state queries/updates with RW lock
Wrap all keyboard state updates, and all pointer/stylus/touch cursor
position with a write lock, and ::query_state() (The only entrypoint
to this state from other threads) with a read lock.

The principle is that query_state may be called from different threads
(UI so far, but maybe KMS too in the future), while the input thread
may (or may not) be updating it. This state is fetched "atomically"
(eg. x/y will be consistently old or new, if the input thread were
updating it at the same time).

There's other places deep in backends/native that read this state,
they all will run in the input thread, so they count as "other readers"
to the other thread. Those changes are already mutually exclusive with
updates, so they don't explicitly need the RW lock.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
1609d1459e backends/native: Move MetaInputSettings ownership to MetaSeatImpl
Together with keymaps and devices, MetaInputSettings will live in the
ninth circle of hell with MetaSeatImpl, forever tied to it.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
2c1558ddbd backends: Make device tracking at MetaInputSettings ad-hoc API
Depending on the backend, we want to integrate this object at different
levels. It will sit close to the MetaBackendX11/MetaSeatX11 in X11, but
it will be put deep down with MetaSeatImpl in the native backend, in a
separate thread.

Since we can't depend on a single object type, nor are able to track
ClutterSeat signals neatly, make this API something to be called
explicitly by backends.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00
Carlos Garnacho
c601a824e9 clutter: Update device for the current tool in backends
This should happen deeper in backends, not here in clutter-main.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
2020-11-27 15:14:33 +00:00