For backwards compatibility we can't do a pointer NULL check on
seat->keyboard or seat->pointer since those members were not pointers
in older Weston SDK's. We only initialize them primarily to make
the extension work on the headless backend (which doesn't init a
pointer/keyboard), thus use isHeadless() as the condition for
initialization.
Signed-off-by: U. Artie Eoff <ullysses.a.eoff@intel.com>
struct weston_seat *seat(Globals::seat());
- if (not seat->pointer) {
+ if (isHeadless()) {
weston_seat_init_pointer(seat);
- }
-
- if (not seat->keyboard) {
weston_seat_init_keyboard(seat, NULL);
}
}