Commit bf174aca authored by Rui Matos's avatar Rui Matos
Browse files

cursor: Disable if running under a wayland session

This plugin is harmful in a wayland session because it tells XWayland
to never show a cursor which results in mutter always using the
default cursor on X clients, e.g. the cursor doesn't change to a caret
on text widgets and doesn't change to the resize cursor on window
edges for those clients' windows.

The reason why the plugin doesn't work is that it uses the GDK device
manager to enumerate devices which only knows about the virtual
XWayland devices and then tries to use those devices to ask for idle
monitors on them through the gnome-desktop API which calls out to
mutter through DBus, but mutter doesn't know about those devices since
it's managing the devices itself.

Basically, this plugin's functionality needs to be implemented by
mutter itself when running as a native wayland compositor.

https://bugzilla.gnome.org/show_bug.cgi?id=738009
parent 6c2bbfce
......@@ -40,6 +40,7 @@
#define GNOME_DESKTOP_USE_UNSTABLE_API
#include <libgnome-desktop/gnome-idle-monitor.h>
#include "gnome-settings-bus.h"
#include "gnome-settings-profile.h"
#include "gsd-cursor-manager.h"
#include "gsd-input-helper.h"
......@@ -387,6 +388,11 @@ gsd_cursor_manager_start (GsdCursorManager *manager,
{
GdkDeviceManager *device_manager;
if (gnome_settings_is_wayland ()) {
g_debug ("Running under a wayland compositor, disabling");
return TRUE;
}
g_debug ("Starting cursor manager");
gnome_settings_profile_start (NULL);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment