diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/drivers/lcd-1bit-vert.c | 2 | ||||
-rw-r--r-- | firmware/drivers/lcd-2bit-vi.c | 2 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/lcd-bitmap.c | 2 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/lcd-charcells.c | 2 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/lcd-remote-bitmap.c | 4 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/system-sdl.c | 6 | ||||
-rw-r--r-- | firmware/target/hosted/sdl/system-sdl.h | 1 |
7 files changed, 6 insertions, 13 deletions
diff --git a/firmware/drivers/lcd-1bit-vert.c b/firmware/drivers/lcd-1bit-vert.c index fcf5dfcc47..fd77ba7578 100644 --- a/firmware/drivers/lcd-1bit-vert.c +++ b/firmware/drivers/lcd-1bit-vert.c | |||
@@ -105,9 +105,7 @@ void LCDFN(update_viewport_rect)(int x, int y, int width, int height) | |||
105 | void LCDFN(init)(void) | 105 | void LCDFN(init)(void) |
106 | { | 106 | { |
107 | LCDFN(clear_display)(); | 107 | LCDFN(clear_display)(); |
108 | #ifndef SIMULATOR | ||
109 | LCDFN(init_device)(); | 108 | LCDFN(init_device)(); |
110 | #endif | ||
111 | #ifdef MAIN_LCD | 109 | #ifdef MAIN_LCD |
112 | scroll_init(); | 110 | scroll_init(); |
113 | #endif | 111 | #endif |
diff --git a/firmware/drivers/lcd-2bit-vi.c b/firmware/drivers/lcd-2bit-vi.c index 803a3678d0..5dd94a15a0 100644 --- a/firmware/drivers/lcd-2bit-vi.c +++ b/firmware/drivers/lcd-2bit-vi.c | |||
@@ -122,9 +122,7 @@ void LCDFN(init)(void) | |||
122 | { | 122 | { |
123 | LCDFN(set_viewport)(NULL); | 123 | LCDFN(set_viewport)(NULL); |
124 | LCDFN(clear_display)(); | 124 | LCDFN(clear_display)(); |
125 | #ifndef SIMULATOR | ||
126 | LCDFN(init_device)(); | 125 | LCDFN(init_device)(); |
127 | #endif | ||
128 | #ifdef MAIN_LCD | 126 | #ifdef MAIN_LCD |
129 | scroll_init(); | 127 | scroll_init(); |
130 | #endif | 128 | #endif |
diff --git a/firmware/target/hosted/sdl/lcd-bitmap.c b/firmware/target/hosted/sdl/lcd-bitmap.c index 6dfbffff37..7058b26e8c 100644 --- a/firmware/target/hosted/sdl/lcd-bitmap.c +++ b/firmware/target/hosted/sdl/lcd-bitmap.c | |||
@@ -160,7 +160,7 @@ void sim_backlight(int value) | |||
160 | #endif /* HAVE_BACKLIGHT */ | 160 | #endif /* HAVE_BACKLIGHT */ |
161 | 161 | ||
162 | /* initialise simulator lcd driver */ | 162 | /* initialise simulator lcd driver */ |
163 | void sim_lcd_init(void) | 163 | void lcd_init_device(void) |
164 | { | 164 | { |
165 | #if LCD_DEPTH == 16 | 165 | #if LCD_DEPTH == 16 |
166 | lcd_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, | 166 | lcd_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, |
diff --git a/firmware/target/hosted/sdl/lcd-charcells.c b/firmware/target/hosted/sdl/lcd-charcells.c index 900cbb04dd..9ceb5de391 100644 --- a/firmware/target/hosted/sdl/lcd-charcells.c +++ b/firmware/target/hosted/sdl/lcd-charcells.c | |||
@@ -106,7 +106,7 @@ void sim_backlight(int value) | |||
106 | #endif | 106 | #endif |
107 | 107 | ||
108 | /* initialise simulator lcd driver */ | 108 | /* initialise simulator lcd driver */ |
109 | void sim_lcd_init(void) | 109 | void lcd_init_device(void) |
110 | { | 110 | { |
111 | lcd_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, | 111 | lcd_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, |
112 | SIM_LCD_WIDTH * display_zoom, | 112 | SIM_LCD_WIDTH * display_zoom, |
diff --git a/firmware/target/hosted/sdl/lcd-remote-bitmap.c b/firmware/target/hosted/sdl/lcd-remote-bitmap.c index 9972f3e423..86d45ef446 100644 --- a/firmware/target/hosted/sdl/lcd-remote-bitmap.c +++ b/firmware/target/hosted/sdl/lcd-remote-bitmap.c | |||
@@ -98,8 +98,10 @@ void sim_remote_backlight(int value) | |||
98 | } | 98 | } |
99 | 99 | ||
100 | /* initialise simulator lcd remote driver */ | 100 | /* initialise simulator lcd remote driver */ |
101 | void sim_lcd_remote_init(void) | 101 | void lcd_remote_init_device(void) |
102 | { | 102 | { |
103 | if (!showremote) | ||
104 | return; | ||
103 | remote_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, | 105 | remote_surface = SDL_CreateRGBSurface(SDL_SWSURFACE, |
104 | LCD_REMOTE_WIDTH * display_zoom, | 106 | LCD_REMOTE_WIDTH * display_zoom, |
105 | LCD_REMOTE_HEIGHT * display_zoom, | 107 | LCD_REMOTE_HEIGHT * display_zoom, |
diff --git a/firmware/target/hosted/sdl/system-sdl.c b/firmware/target/hosted/sdl/system-sdl.c index 9d529de37f..7ab6fd2c34 100644 --- a/firmware/target/hosted/sdl/system-sdl.c +++ b/firmware/target/hosted/sdl/system-sdl.c | |||
@@ -140,12 +140,6 @@ static int sdl_event_thread(void * param) | |||
140 | 140 | ||
141 | SDL_WM_SetCaption(UI_TITLE, NULL); | 141 | SDL_WM_SetCaption(UI_TITLE, NULL); |
142 | 142 | ||
143 | sim_lcd_init(); | ||
144 | #ifdef HAVE_REMOTE_LCD | ||
145 | if (showremote) | ||
146 | sim_lcd_remote_init(); | ||
147 | #endif | ||
148 | |||
149 | if (background && picture_surface != NULL) | 143 | if (background && picture_surface != NULL) |
150 | SDL_BlitSurface(picture_surface, NULL, gui_surface, NULL); | 144 | SDL_BlitSurface(picture_surface, NULL, gui_surface, NULL); |
151 | 145 | ||
diff --git a/firmware/target/hosted/sdl/system-sdl.h b/firmware/target/hosted/sdl/system-sdl.h index ad7aa709ab..e87f096617 100644 --- a/firmware/target/hosted/sdl/system-sdl.h +++ b/firmware/target/hosted/sdl/system-sdl.h | |||
@@ -47,6 +47,7 @@ void sys_handle_argv(int argc, char *argv[]); | |||
47 | void gui_message_loop(void); | 47 | void gui_message_loop(void); |
48 | 48 | ||
49 | extern bool background; /* True if the background image is enabled */ | 49 | extern bool background; /* True if the background image is enabled */ |
50 | extern bool showremote; | ||
50 | extern int display_zoom; | 51 | extern int display_zoom; |
51 | extern long start_tick; | 52 | extern long start_tick; |
52 | 53 | ||