]> git.webhop.me Git - lcd4linux.git/commitdiff
GPO cleanup
authormichael <michael@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>
Sat, 20 Jan 2007 13:52:43 +0000 (13:52 +0000)
committermichael <michael@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>
Sat, 20 Jan 2007 13:52:43 +0000 (13:52 +0000)
git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@751 3ae390bd-cb1e-0410-b409-cd5a39f66f1f

drv_generic_gpio.c
widget_gpo.c
widget_gpo.h

index f2d3a60b40710c9e6bb9842f99b9de4fc591daf9..0bf919fb06be9c0a09f0ec550b5b38f5bad030d5 100644 (file)
@@ -219,8 +219,10 @@ int drv_generic_gpio_get(const int num)
 int drv_generic_gpio_draw(WIDGET * W)
 {
     WIDGET_GPO *gpo = W->data;
-    int num = gpo->num;
-    int val = gpo->val;
+    int num, val;
+
+    num = W->row;
+    val = P2N(&gpo->expression);
 
     if (num < 0 || num >= GPOS) {
        error("%s: gpio_draw(%d): GPO out of range (0..%d)", Driver, num + 1, GPOS);
index 4b925717aea63be85b5e0ddc5563817913f8e35f..3ac7a4e5a21d0890cbe00de8114462658e52c005 100644 (file)
@@ -59,9 +59,6 @@ void widget_gpo_update(void *Self)
     property_eval(&GPO->expression);
     property_eval(&GPO->update);
 
-    GPO->num = W->row;
-    GPO->val = P2N(&GPO->expression);
-
     /* finally, draw it! */
     if (W->class->draw)
        W->class->draw(W);
index 6f8e1558713145d2f85446fbaa955722b057bc1b..3ee8905be18d69d571119a281b0a3922c32ecf3a 100644 (file)
@@ -33,8 +33,6 @@
 typedef struct WIDGET_GPO {
     PROPERTY expression;       /* main GPO expression */
     PROPERTY update;           /* update interval (msec) */
-    int num;                   /* GPO number */
-    int val;                   /* GPO value */
 } WIDGET_GPO;