Skip to content
  • Derek Foreman's avatar
    input: Don't test keyboard/pointer/touch pointers · 1281a36e
    Derek Foreman authored
    
    
    Keyboards and pointers aren't freed when devices are removed, so we should
    really be testing keyboard_device_count and pointer_device_count in most
    cases, not the actual pointers. Otherwise we end up with different
    behaviour after removing a device than we had before it was inserted.
    
    This commit renames the touch/keyboard/pointer pointers and adds helper
    functions to get them that hide this complexity and return NULL when
    *_device_count is 0.
    
    Signed-off-by: default avatarDerek Foreman <derekf@osg.samsung.com>
    Reviewed-by: default avatarJonas Ådahl <jadahl@gmail.com>
    1281a36e