diff options
Diffstat (limited to 'uisimulator/sdl')
-rw-r--r-- | uisimulator/sdl/button.c | 10 | ||||
-rw-r--r-- | uisimulator/sdl/lcd-bitmap.c | 8 | ||||
-rw-r--r-- | uisimulator/sdl/lcd-charcells.c | 2 |
3 files changed, 10 insertions, 10 deletions
diff --git a/uisimulator/sdl/button.c b/uisimulator/sdl/button.c index 4b03008497..0c5f4f7d0b 100644 --- a/uisimulator/sdl/button.c +++ b/uisimulator/sdl/button.c | |||
@@ -49,7 +49,7 @@ struct event_queue button_queue; | |||
49 | 49 | ||
50 | static int btn = 0; /* Hopefully keeps track of currently pressed keys... */ | 50 | static int btn = 0; /* Hopefully keeps track of currently pressed keys... */ |
51 | 51 | ||
52 | #if CONFIG_BACKLIGHT | 52 | #ifdef HAVE_BACKLIGHT |
53 | static bool filter_first_keypress; | 53 | static bool filter_first_keypress; |
54 | 54 | ||
55 | void set_backlight_filter_keypress(bool value) | 55 | void set_backlight_filter_keypress(bool value) |
@@ -90,7 +90,7 @@ void button_event(int key, bool pressed) | |||
90 | static int repeat_count = 0; | 90 | static int repeat_count = 0; |
91 | static bool repeat = false; | 91 | static bool repeat = false; |
92 | static bool post = false; | 92 | static bool post = false; |
93 | #if CONFIG_BACKLIGHT | 93 | #ifdef HAVE_BACKLIGHT |
94 | static bool skip_release = false; | 94 | static bool skip_release = false; |
95 | #ifdef HAVE_REMOTE_LCD | 95 | #ifdef HAVE_REMOTE_LCD |
96 | static bool skip_remote_release = false; | 96 | static bool skip_remote_release = false; |
@@ -568,7 +568,7 @@ void button_event(int key, bool pressed) | |||
568 | diff = btn ^ lastbtn; | 568 | diff = btn ^ lastbtn; |
569 | if(diff && (btn & diff) == 0) | 569 | if(diff && (btn & diff) == 0) |
570 | { | 570 | { |
571 | #if CONFIG_BACKLIGHT | 571 | #ifdef HAVE_BACKLIGHT |
572 | #ifdef HAVE_REMOTE_LCD | 572 | #ifdef HAVE_REMOTE_LCD |
573 | if(diff & BUTTON_REMOTE) | 573 | if(diff & BUTTON_REMOTE) |
574 | if(!skip_remote_release) | 574 | if(!skip_remote_release) |
@@ -635,7 +635,7 @@ void button_event(int key, bool pressed) | |||
635 | if (queue_empty(&button_queue)) | 635 | if (queue_empty(&button_queue)) |
636 | { | 636 | { |
637 | queue_post(&button_queue, BUTTON_REPEAT | btn, 0); | 637 | queue_post(&button_queue, BUTTON_REPEAT | btn, 0); |
638 | #if CONFIG_BACKLIGHT | 638 | #ifdef HAVE_BACKLIGHT |
639 | #ifdef HAVE_REMOTE_LCD | 639 | #ifdef HAVE_REMOTE_LCD |
640 | if(btn & BUTTON_REMOTE) | 640 | if(btn & BUTTON_REMOTE) |
641 | { | 641 | { |
@@ -652,7 +652,7 @@ void button_event(int key, bool pressed) | |||
652 | } | 652 | } |
653 | else | 653 | else |
654 | { | 654 | { |
655 | #if CONFIG_BACKLIGHT | 655 | #ifdef HAVE_BACKLIGHT |
656 | #ifdef HAVE_REMOTE_LCD | 656 | #ifdef HAVE_REMOTE_LCD |
657 | if (btn & BUTTON_REMOTE) { | 657 | if (btn & BUTTON_REMOTE) { |
658 | if (!remote_filter_first_keypress || is_remote_backlight_on()) | 658 | if (!remote_filter_first_keypress || is_remote_backlight_on()) |
diff --git a/uisimulator/sdl/lcd-bitmap.c b/uisimulator/sdl/lcd-bitmap.c index 3adb72b6d6..da6acce1bc 100644 --- a/uisimulator/sdl/lcd-bitmap.c +++ b/uisimulator/sdl/lcd-bitmap.c | |||
@@ -25,7 +25,7 @@ SDL_Surface* lcd_surface; | |||
25 | int lcd_backlight_val; | 25 | int lcd_backlight_val; |
26 | 26 | ||
27 | #if LCD_DEPTH <= 8 | 27 | #if LCD_DEPTH <= 8 |
28 | #if CONFIG_BACKLIGHT | 28 | #ifdef HAVE_BACKLIGHT |
29 | SDL_Color lcd_backlight_color_zero = {UI_LCD_BGCOLORLIGHT, 0}; | 29 | SDL_Color lcd_backlight_color_zero = {UI_LCD_BGCOLORLIGHT, 0}; |
30 | #endif | 30 | #endif |
31 | SDL_Color lcd_color_zero = {UI_LCD_BGCOLOR, 0}; | 31 | SDL_Color lcd_color_zero = {UI_LCD_BGCOLOR, 0}; |
@@ -71,7 +71,7 @@ void lcd_update_rect(int x_start, int y_start, int width, int height) | |||
71 | LCD_HEIGHT, background ? UI_LCD_POSX : 0, background? UI_LCD_POSY : 0); | 71 | LCD_HEIGHT, background ? UI_LCD_POSX : 0, background? UI_LCD_POSY : 0); |
72 | } | 72 | } |
73 | 73 | ||
74 | #if CONFIG_BACKLIGHT | 74 | #ifdef HAVE_BACKLIGHT |
75 | void sim_backlight(int value) | 75 | void sim_backlight(int value) |
76 | { | 76 | { |
77 | lcd_backlight_val = value; | 77 | lcd_backlight_val = value; |
@@ -116,7 +116,7 @@ void sim_lcd_init(void) | |||
116 | #endif | 116 | #endif |
117 | 117 | ||
118 | #if LCD_DEPTH <= 8 | 118 | #if LCD_DEPTH <= 8 |
119 | #if CONFIG_BACKLIGHT | 119 | #ifdef HAVE_BACKLIGHT |
120 | sdl_set_gradient(lcd_surface, &lcd_backlight_color_zero, &lcd_color_max, | 120 | sdl_set_gradient(lcd_surface, &lcd_backlight_color_zero, &lcd_color_max, |
121 | 0, (1<<LCD_DEPTH)); | 121 | 0, (1<<LCD_DEPTH)); |
122 | #else | 122 | #else |
@@ -132,7 +132,7 @@ void sim_lcd_ex_init(int shades, unsigned long (*getpixel)(int, int)) | |||
132 | lcd_ex_shades = shades; | 132 | lcd_ex_shades = shades; |
133 | lcd_ex_getpixel = getpixel; | 133 | lcd_ex_getpixel = getpixel; |
134 | if (shades) { | 134 | if (shades) { |
135 | #if CONFIG_BACKLIGHT | 135 | #ifdef HAVE_BACKLIGHT |
136 | if (lcd_backlight_val > 0) { | 136 | if (lcd_backlight_val > 0) { |
137 | sdl_set_gradient(lcd_surface, &lcd_color_max, | 137 | sdl_set_gradient(lcd_surface, &lcd_color_max, |
138 | &lcd_backlight_color_zero, (1<<LCD_DEPTH), | 138 | &lcd_backlight_color_zero, (1<<LCD_DEPTH), |
diff --git a/uisimulator/sdl/lcd-charcells.c b/uisimulator/sdl/lcd-charcells.c index 5a08179232..722933f002 100644 --- a/uisimulator/sdl/lcd-charcells.c +++ b/uisimulator/sdl/lcd-charcells.c | |||
@@ -71,7 +71,7 @@ void lcd_update(void) | |||
71 | LCD_HEIGHT*CHAR_HEIGHT*CHAR_PIXEL); | 71 | LCD_HEIGHT*CHAR_HEIGHT*CHAR_PIXEL); |
72 | } | 72 | } |
73 | 73 | ||
74 | #if CONFIG_BACKLIGHT | 74 | #ifdef HAVE_BACKLIGHT |
75 | void sim_backlight(int value) | 75 | void sim_backlight(int value) |
76 | { | 76 | { |
77 | if (value > 0) { | 77 | if (value > 0) { |