From: Michael R. <re...@eu...> - 2006-02-21 06:10:24
|
Hi Chri, > The attached patch adds a new keypad widget and a generic > keypad driver. The widget is unique because I believe it's > the only one that doesn't update with a timer, instead, it > uses, you guessed it, the key pad. :) The generic driver > is useful for mapping key scan codes from the hardware into > normal positions UP, DOWN, LEFT, RIGHT, etc. so that if you > swap hardware you won't need to re-write the configuration > file that much. Hey, that's great news! Finally LCD4Linux gets support for keys! I already committed your patch to CVS. I cannot test it at the moment, because I'd have to dig out a display with keys... I'm really surprised how neat you did integrate things... registering the widget in the generic driver init is the right thing, but it's not self-evident. Great Work! But there is one thing I don't like that much: your extension of the widget structure, especially the two new function pointers 'update' and 'find'. First, I'd say that a keypad widget never has a 'draw' function. So I'd suggest removing the update function and use w->draw instead. I'm not shure about the find call. I'd accept a generic 'widget_find()" function, but i'm unhappy with a widget specific find() callback, because it's very keypad-specific.... maybe we can find a cleaner way to implement this.... by,e Michael -- Michael Reinelt <re...@eu...> http://home.pages.at/reinelt GPG-Key 0xDF13BA50 ICQ #288386781 |