View Single Post
Old 12-10-2012, 11:35 PM   #821
eureka
but forgot what it's like
eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.eureka ought to be getting tired of karma fortunes by now.
 
Posts: 741
Karma: 2345678
Join Date: Dec 2011
Location: north (by northwest)
Device: Kindle Touch
Quote:
Originally Posted by dave2008 View Post
Ok, touch coordinates are handled now. Let me know if it works or not
Works fine with the small patch:
Code:
diff --git a/frontend/ui/inputevent.lua b/frontend/ui/inputevent.lua
index daa21ec..4c5712d 100644
--- a/frontend/ui/inputevent.lua
+++ b/frontend/ui/inputevent.lua
@@ -272,11 +272,12 @@ function Input:init()
                                        --@TODO handle coordinates properly after
                                        --screen rotate.    (houqp)
                                        if ev.code == ABS_MT_POSITION_X then
-                                               ev.code = math.round(ev.code * (600/4095))
+                                               ev.value = math.round(ev.value * (600/4095))
                                        elseif ev.code == ABS_MT_POSITION_Y then
-                                               ev.code = math.round(ev.code * (800/4095))
+                                               ev.value = math.round(ev.value * (800/4095))
                                        end
                                end
+                               return ev
                        end
                        print("Auto-detected Kindle Touch")
                elseif dev_mod == "Kindle4" then
E Ink module is also works filne on KT now.
eureka is offline   Reply With Quote