RFC/pull: evdev input for android, and touch fixes

Pekka Paalanen ppaalanen at gmail.com
Thu Jul 5 03:27:31 PDT 2012


Hi Kristian,

I will be replying to this email with a patch series for Wayland and
Weston, that will make evdev input devices work on Android.

It splits udev and weston-launcher related code out from evdev.c, so I
can reuse evdev.c on Android. That is the bulk of the work. There are
various bug fixes, especially for touch devices, which apparently have
not been tested after the wl_seat conversion. Found input devices are
printed to the log, for both drm and android backends.

In the end, on a Galaxy Nexus device, I have the three buttons working
as a keyboard, and the touchscreen as a touch device, which simple-touch
confirms to be working.

I have also tested the DRM backend on my laptop, with
hotplugging/removing a mouse, to check that I did not break anything.

The Wayland patches are only as email, but the Weston series can also
be found in a branch:

The following changes since commit 1248158e7d9a14cbed14b47c83bf83d4ca61ec91:

  compositor-x11: Set make and model so we don't send NULL strings (2012-07-02 21:24:57 -0400)

are available in the git repository at:
  git://git.collabora.co.uk/git/user/pq/wayland-demos.git for-krh

Pekka Paalanen (17):
      simple-touch: respond to ping protocol
      evdev: roughly split udev-related code out
      evdev: merge evdev-private.h into evdev.h
      uevdev: rename API functions
      evdev: split udev members from struct evdev_seat
      evdev: move weston_launcher_open() call site
      evdev: open input devices as close-on-exec
      android: build evdev.c into android backend
      evdev: move seat_id into uevdev
      evdev: don't crash on missing keyboard
      evdev: query position ranges for MT, too
      evdev: fix touch screen detection
      evdev: log input devices
      compositor-drm: log enter/leave VT
      compositor: log program launches
      android: add basic evdev input support
      compositor: rework touch focus

 clients/simple-touch.c   |   31 +++++-
 configure.ac             |    1 +
 src/Makefile.am          |   19 ++-
 src/compositor-android.c |   85 +++++++++++++-
 src/compositor-drm.c     |   18 ++--
 src/compositor-openwfd.c |    4 +-
 src/compositor.c         |   64 +++-------
 src/compositor.h         |    4 -
 src/evdev-private.h      |  115 ------------------
 src/evdev-touchpad.c     |    2 +-
 src/evdev.c              |  290 +++++++++-------------------------------------
 src/evdev.h              |  109 +++++++++++++++--
 src/udev-evdev.c         |  278 ++++++++++++++++++++++++++++++++++++++++++++
 src/udev-evdev.h         |   47 ++++++++
 14 files changed, 633 insertions(+), 434 deletions(-)
 delete mode 100644 src/evdev-private.h
 create mode 100644 src/udev-evdev.c
 create mode 100644 src/udev-evdev.h

Finally, a question:

It seems structs wl_pointer, wl_keyboard, and wl_touch have a
destroy listener only for focus_resource, but not for the focus
(surface). Should the other listener be added, or is it handled by some
unobvious way? What about making a 'struct focus' for containing all
the common focus-related fields in the three structs, with common
callback functions for listeners?


Thanks,
pq



More information about the wayland-devel mailing list