summaryrefslogtreecommitdiff
path: root/uisimulator/x11/button-x11.c
diff options
context:
space:
mode:
Diffstat (limited to 'uisimulator/x11/button-x11.c')
-rw-r--r--uisimulator/x11/button-x11.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/uisimulator/x11/button-x11.c b/uisimulator/x11/button-x11.c
index b2d8ab6c7a..e037867caf 100644
--- a/uisimulator/x11/button-x11.c
+++ b/uisimulator/x11/button-x11.c
@@ -21,6 +21,7 @@
21#include "button.h" 21#include "button.h"
22#include "kernel.h" 22#include "kernel.h"
23#include "debug.h" 23#include "debug.h"
24#include "backlight.h"
24#include "misc.h" 25#include "misc.h"
25 26
26#include "X11/keysym.h" 27#include "X11/keysym.h"
@@ -47,7 +48,7 @@ static long lastbtn; /* Last valid button status */
47/* mostly copied from real button.c */ 48/* mostly copied from real button.c */
48void button_read (void); 49void button_read (void);
49 50
50void button_tick(void) 51static void button_tick(void)
51{ 52{
52 static int tick = 0; 53 static int tick = 0;
53 static int count = 0; 54 static int count = 0;
@@ -117,6 +118,13 @@ void button_tick(void)
117 queue_post(&button_queue, BUTTON_REPEAT | btn, NULL); 118 queue_post(&button_queue, BUTTON_REPEAT | btn, NULL);
118 else 119 else
119 queue_post(&button_queue, btn, NULL); 120 queue_post(&button_queue, btn, NULL);
121#ifdef HAVE_REMOTE_LCD
122 if(btn & BUTTON_REMOTE)
123 remote_backlight_on();
124 else
125#endif
126 backlight_on();
127
120 } 128 }
121 } 129 }
122 else 130 else
@@ -276,6 +284,7 @@ long button_get_w_tmo(int ticks)
276 284
277void button_init(void) 285void button_init(void)
278{ 286{
287 tick_add_task(button_tick);
279} 288}
280 289
281int button_status(void) 290int button_status(void)