Quote:
Originally Posted by Cykotitan
I am amazed by your work. I've just been experimenting on my paperwhite and I made it possible to click by editing config.lua:
...
|
Awesome! Thank you! That works really well.
To make it work in landscape mode I had to swap Y and X, and invert Y:
Code:
clickevent = 0
x, y = 0, 0
-- this handler will be called upon key presses (input events, actually)
function handleInput(channel, itype, code, value)
if itype == 3 then
if code == 57 then
clickevent = value + 1
if x and y then
SendPointerEvent(y, x, 0)
end
elseif code == 53 then
x = value
elseif code == 54 then
y = math.abs(value - 1024)
if clickevent == 1 then
SendPointerEvent(y, x, 1)
end
end
end
It seems you were also missing an "end" at the end, but otherwise that works great!
Now, if only there was a way to rotate the screen without having to SSH into it while reading a book in landscape...