@ -297,6 +297,29 @@ evdev_device_set_output(struct evdev_device *device,
& device - > output_destroy_listener ) ;
& device - > output_destroy_listener ) ;
}
}
static void
configure_device ( struct evdev_device * device )
{
struct weston_compositor * compositor = device - > seat - > compositor ;
struct weston_config_section * s ;
int enable_tap ;
int enable_tap_default ;
s = weston_config_get_section ( compositor - > config ,
" libinput " , NULL , NULL ) ;
if ( libinput_device_config_tap_get_finger_count ( device - > device ) > 0 ) {
enable_tap_default =
libinput_device_config_tap_get_default_enabled (
device - > device ) ;
weston_config_section_get_bool ( s , " enable_tap " ,
& enable_tap ,
enable_tap_default ) ;
libinput_device_config_tap_set_enabled ( device - > device ,
enable_tap ) ;
}
}
struct evdev_device *
struct evdev_device *
evdev_device_create ( struct libinput_device * libinput_device ,
evdev_device_create ( struct libinput_device * libinput_device ,
struct weston_seat * seat )
struct weston_seat * seat )
@ -330,6 +353,8 @@ evdev_device_create(struct libinput_device *libinput_device,
libinput_device_set_user_data ( libinput_device , device ) ;
libinput_device_set_user_data ( libinput_device , device ) ;
libinput_device_ref ( libinput_device ) ;
libinput_device_ref ( libinput_device ) ;
configure_device ( device ) ;
return device ;
return device ;
}
}