diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2020-07-19 19:38:45 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2020-07-24 21:20:13 +0000 |
commit | 0c4f89370d05056faa789aa9cabcccc4e509fb9f (patch) | |
tree | 6ddf7fff0a47564db41d39927ea1acbdb03e74ee /uisimulator/common/sim_icons.c | |
parent | 092c340a2062fa98b7387fc5fd63578ddae7d0b6 (diff) | |
download | rockbox-0c4f89370d05056faa789aa9cabcccc4e509fb9f.tar.gz rockbox-0c4f89370d05056faa789aa9cabcccc4e509fb9f.zip |
[2/4] get rid of HAVE_LCD_CHARCELLS
HAVE_LCD_BITMAP is now redundant.
lcd_bitmap is always-on in features.txt so manual and lang strings
don't have to change
Change-Id: I08eeb20de48099ffc2dc23782711af368c2ec794
Diffstat (limited to 'uisimulator/common/sim_icons.c')
-rw-r--r-- | uisimulator/common/sim_icons.c | 312 |
1 files changed, 0 insertions, 312 deletions
diff --git a/uisimulator/common/sim_icons.c b/uisimulator/common/sim_icons.c deleted file mode 100644 index b72f6003e8..0000000000 --- a/uisimulator/common/sim_icons.c +++ /dev/null | |||
@@ -1,312 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 Mats Lidell <matsl@contactor.se> | ||
11 | * | ||
12 | * This program is free software; you can redistribute it and/or | ||
13 | * modify it under the terms of the GNU General Public License | ||
14 | * as published by the Free Software Foundation; either version 2 | ||
15 | * of the License, or (at your option) any later version. | ||
16 | * | ||
17 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
18 | * KIND, either express or implied. | ||
19 | * | ||
20 | ****************************************************************************/ | ||
21 | #include <stdio.h> | ||
22 | #include "config.h" | ||
23 | |||
24 | #include <lcd.h> | ||
25 | #include <kernel.h> | ||
26 | #include <string.h> | ||
27 | #include <debug.h> | ||
28 | |||
29 | extern void lcd_print_icon(int x, int icon_line, bool enable, char **icon); | ||
30 | |||
31 | static char* icon_battery_bit[]= | ||
32 | { | ||
33 | "-----", | ||
34 | " ", | ||
35 | "*****", | ||
36 | "*****", | ||
37 | "*****", | ||
38 | "*****", | ||
39 | "*****", | ||
40 | "*****", | ||
41 | " ", | ||
42 | "-----", | ||
43 | NULL | ||
44 | }; | ||
45 | |||
46 | static char* icon_battery[]= | ||
47 | { | ||
48 | "********************* ", | ||
49 | "* * ", | ||
50 | "* ----- ----- ----- * ", | ||
51 | "* ----- ----- ----- ***", | ||
52 | "* ----- ----- ----- * *", | ||
53 | "* ----- ----- ----- * *", | ||
54 | "* ----- ----- ----- ***", | ||
55 | "* ----- ----- ----- * ", | ||
56 | "* * ", | ||
57 | "********************* ", | ||
58 | NULL | ||
59 | }; | ||
60 | |||
61 | static char* icon_volume[]= | ||
62 | { | ||
63 | " ", | ||
64 | " ", | ||
65 | " ", | ||
66 | " ", | ||
67 | "* * * ", | ||
68 | "* * * ", | ||
69 | " * * *** * ", | ||
70 | " * * * * * ", | ||
71 | " * * * * ", | ||
72 | " * *** * ", | ||
73 | NULL | ||
74 | }; | ||
75 | |||
76 | static char* icon_volume_1[]= | ||
77 | { | ||
78 | " ", | ||
79 | " ", | ||
80 | " ", | ||
81 | " ", | ||
82 | "**", | ||
83 | "**", | ||
84 | "**", | ||
85 | "**", | ||
86 | "**", | ||
87 | "**", | ||
88 | NULL | ||
89 | }; | ||
90 | |||
91 | static char* icon_volume_2[]= | ||
92 | { | ||
93 | " ", | ||
94 | " ", | ||
95 | " ", | ||
96 | "**", | ||
97 | "**", | ||
98 | "**", | ||
99 | "**", | ||
100 | "**", | ||
101 | "**", | ||
102 | "**", | ||
103 | NULL | ||
104 | }; | ||
105 | |||
106 | static char* icon_volume_3[]= | ||
107 | { | ||
108 | " ", | ||
109 | " ", | ||
110 | "**", | ||
111 | "**", | ||
112 | "**", | ||
113 | "**", | ||
114 | "**", | ||
115 | "**", | ||
116 | "**", | ||
117 | "**", | ||
118 | NULL | ||
119 | }; | ||
120 | |||
121 | static char* icon_volume_4[]= | ||
122 | { | ||
123 | " ", | ||
124 | "**", | ||
125 | "**", | ||
126 | "**", | ||
127 | "**", | ||
128 | "**", | ||
129 | "**", | ||
130 | "**", | ||
131 | "**", | ||
132 | "**", | ||
133 | NULL | ||
134 | }; | ||
135 | |||
136 | static char* icon_volume_5[]= | ||
137 | { | ||
138 | "**", | ||
139 | "**", | ||
140 | "**", | ||
141 | "**", | ||
142 | "**", | ||
143 | "**", | ||
144 | "**", | ||
145 | "**", | ||
146 | "**", | ||
147 | "**", | ||
148 | NULL | ||
149 | }; | ||
150 | |||
151 | static char* icon_pause[]= | ||
152 | { | ||
153 | " **** **** ", | ||
154 | " **** **** ", | ||
155 | " **** **** ", | ||
156 | " **** **** ", | ||
157 | " **** **** ", | ||
158 | " **** **** ", | ||
159 | " **** **** ", | ||
160 | " **** **** ", | ||
161 | " **** **** ", | ||
162 | " **** **** ", | ||
163 | NULL | ||
164 | }; | ||
165 | |||
166 | static char* icon_play[]= | ||
167 | { | ||
168 | "** ", | ||
169 | "***** ", | ||
170 | "******* ", | ||
171 | "********* ", | ||
172 | "*********** ", | ||
173 | "********* ", | ||
174 | "******* ", | ||
175 | "***** ", | ||
176 | "** ", | ||
177 | " ", | ||
178 | NULL | ||
179 | }; | ||
180 | |||
181 | static char* icon_record[]= | ||
182 | { | ||
183 | " *** ", | ||
184 | " ***** ", | ||
185 | " ******* ", | ||
186 | " ********* ", | ||
187 | " ********* ", | ||
188 | " ********* ", | ||
189 | " ******* ", | ||
190 | " ***** ", | ||
191 | " *** ", | ||
192 | " ", | ||
193 | NULL | ||
194 | }; | ||
195 | |||
196 | static char* icon_usb[]= | ||
197 | { | ||
198 | " ********* ", | ||
199 | " ** ** ", | ||
200 | " * ", | ||
201 | " ** * ** ", | ||
202 | "***********************", | ||
203 | " ** * ** ", | ||
204 | " * ", | ||
205 | " ** ** ", | ||
206 | " ******** ", | ||
207 | " ** ", | ||
208 | NULL | ||
209 | }; | ||
210 | |||
211 | static char* icon_audio[]= | ||
212 | { | ||
213 | " *************************** ", | ||
214 | " ** ** ", | ||
215 | "* ** * * **** * *** *", | ||
216 | "* * * * * * * * * * *", | ||
217 | "* * * * * * * * * * *", | ||
218 | "* ****** * * * * * * * *", | ||
219 | "* * * * * * * * * * *", | ||
220 | "* * * *** **** * *** *", | ||
221 | " ** ** ", | ||
222 | " *************************** ", | ||
223 | NULL | ||
224 | }; | ||
225 | |||
226 | static char* icon_param[]= | ||
227 | { | ||
228 | " ********************************* ", | ||
229 | " ** ** ", | ||
230 | "* **** ** **** ** ** ** *", | ||
231 | "* * * * * * * * * ** ** *", | ||
232 | "* * * * * * * * * * * * * *", | ||
233 | "* **** ****** **** ****** * * * * *", | ||
234 | "* * * * * * * * * * * *", | ||
235 | "* * * * * * * * * * * *", | ||
236 | " ** ** ", | ||
237 | " ********************************* ", | ||
238 | NULL | ||
239 | }; | ||
240 | |||
241 | static char* icon_repeat[]= | ||
242 | { | ||
243 | " ", | ||
244 | " *************", | ||
245 | " * ", | ||
246 | " * ", | ||
247 | "* ", | ||
248 | "* ", | ||
249 | "* ** ", | ||
250 | " * **** ", | ||
251 | " * ****** ", | ||
252 | " *************", | ||
253 | NULL | ||
254 | }; | ||
255 | |||
256 | static char* icon_repeat2[]= | ||
257 | { | ||
258 | " ", | ||
259 | " *", | ||
260 | " **", | ||
261 | "***", | ||
262 | " *", | ||
263 | " *", | ||
264 | " *", | ||
265 | " *", | ||
266 | " *", | ||
267 | " *", | ||
268 | NULL | ||
269 | }; | ||
270 | |||
271 | |||
272 | struct icon_info | ||
273 | { | ||
274 | char** bitmap; | ||
275 | int xpos; | ||
276 | int row; | ||
277 | }; | ||
278 | |||
279 | #define ICON_VOLUME_POS 102 | ||
280 | #define ICON_VOLUME_SIZE 14 | ||
281 | #define ICON_VOLUME_X_SIZE 2 | ||
282 | |||
283 | static struct icon_info icons [] = | ||
284 | { | ||
285 | |||
286 | {icon_battery, 0, 0}, | ||
287 | {icon_battery_bit, 2, 0}, | ||
288 | {icon_battery_bit, 8, 0}, | ||
289 | {icon_battery_bit, 14, 0}, | ||
290 | {icon_usb, 0, 1}, | ||
291 | {icon_play, 36, 0}, | ||
292 | {icon_record, 48, 0}, | ||
293 | {icon_pause, 60, 0}, | ||
294 | {icon_audio, 37, 1}, | ||
295 | {icon_repeat, 74, 0}, | ||
296 | {icon_repeat2, 94, 0}, | ||
297 | {icon_volume, ICON_VOLUME_POS, 0}, | ||
298 | {icon_volume_1, ICON_VOLUME_POS+ICON_VOLUME_SIZE, 0}, | ||
299 | {icon_volume_2, ICON_VOLUME_POS+ICON_VOLUME_SIZE+(1*ICON_VOLUME_X_SIZE)+1, 0}, | ||
300 | {icon_volume_3, ICON_VOLUME_POS+ICON_VOLUME_SIZE+(2*ICON_VOLUME_X_SIZE)+2, 0}, | ||
301 | {icon_volume_4, ICON_VOLUME_POS+ICON_VOLUME_SIZE+(3*ICON_VOLUME_X_SIZE)+3, 0}, | ||
302 | {icon_volume_5, ICON_VOLUME_POS+ICON_VOLUME_SIZE+(4*ICON_VOLUME_X_SIZE)+4, 0}, | ||
303 | {icon_param, 90, 1} | ||
304 | }; | ||
305 | |||
306 | void | ||
307 | lcd_icon(int icon, bool enable) | ||
308 | { | ||
309 | lcd_print_icon(icons[icon].xpos, icons[icon].row, enable, | ||
310 | icons[icon].bitmap); | ||
311 | } | ||
312 | |||