RFC: Listening for devices being added - udev vs. X11

Nick Schermer nick at xfce.org
Mon Apr 21 08:52:07 CEST 2014


Thunar is different in is aspect since it is required to watch for
block/usb events, which is not possible through X, so there gudev
became optional.

Keyboards are a different issue, it is easy to watch those with X and
should therefore be the preferred option. Look at the pointers code
(instead of IsXExtensionPointer use IsXExtensionKeyboard).
Advantage is you have the correct device too, which is probably needed
to set some of the properties as well.

Nick

On Mon, Apr 21, 2014 at 12:52 AM, Martin Kelly <martin at martingkelly.com> wrote:
>> It looks like devd uses a config file, so xfsettingsd would need to add
>> an entry to that. In any case, I don't have a BSD system to test on. How
>> about if I #ifdef this to work only on Linux and if someone else with a
>> BSD system has the time, then they could add the feature in? We could
>> instead use X11, but then we are writing new code that we know will
>> eventually die, which seems like bad design to me.
>
>
> Even more directly, just check for the presence of udev instead of checking
> for Linux.
>
> _______________________________________________
> Xfce4-dev mailing list
> Xfce4-dev at xfce.org
> https://mail.xfce.org/mailman/listinfo/xfce4-dev


More information about the Xfce4-dev mailing list