H2O: Fix initial tap detection (#6832)

* Fix initial tap on the H2O

There's no slot 0, so make sure the initialState doesn't get confused by input's init data that otherwise assumes the main slot is 0
pull/6837/head
NiLuJe 4 years ago committed by GitHub
parent ac3c97af49
commit c810a19040
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -89,8 +89,11 @@ local KoboDaylight = Kobo:new{
local KoboDahlia = Kobo:new{
model = "Kobo_dahlia",
hasFrontlight = yes,
-- NOTE: The hardware can technically track 2 different fingers, but we don't seem to be able to figure it out...
hasMultitouch = no,
touch_phoenix_protocol = true,
-- There's no slot 0, the first finger gets assigned slot 1, and the second slot 2
main_finger_slot = 1,
display_dpi = 265,
-- the bezel covers the top 11 pixels:
viewport = Geom:new{x=0, y=11, w=1080, h=1429},
@ -310,6 +313,16 @@ function Kobo:init()
}
self.wakeup_mgr = WakeupMgr:new()
-- Tweak initial slot, if necessary
if self.main_finger_slot then
self.input.cur_slot = self.main_finger_slot
self.input.ev_slots = {
[self.main_finger_slot] = {
slot = self.main_finger_slot,
}
}
end
Generic.init(self)
-- When present, event2 is the raw accelerometer data (3-Axis Orientation/Motion Detection)

Loading…
Cancel
Save