summaryrefslogtreecommitdiff
path: root/apps/onplay.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/onplay.c')
-rw-r--r--apps/onplay.c42
1 files changed, 14 insertions, 28 deletions
diff --git a/apps/onplay.c b/apps/onplay.c
index e2a6c29374..3ea08fd9e5 100644
--- a/apps/onplay.c
+++ b/apps/onplay.c
@@ -174,8 +174,7 @@ static bool playlist_options(void)
174 174
175 if ((selected_file_attr & TREE_ATTR_MASK) == TREE_ATTR_M3U) 175 if ((selected_file_attr & TREE_ATTR_MASK) == TREE_ATTR_M3U)
176 { 176 {
177 items[i].desc = str(LANG_VIEW); 177 items[i].desc = ID2P(LANG_VIEW);
178 items[i].voice_id = LANG_VIEW;
179 items[i].function = view_playlist; 178 items[i].function = view_playlist;
180 i++; 179 i++;
181 pstart++; 180 pstart++;
@@ -183,38 +182,32 @@ static bool playlist_options(void)
183 182
184 if (mpeg_status() & MPEG_STATUS_PLAY) 183 if (mpeg_status() & MPEG_STATUS_PLAY)
185 { 184 {
186 items[i].desc = str(LANG_INSERT); 185 items[i].desc = ID2P(LANG_INSERT);
187 items[i].voice_id = LANG_INSERT;
188 args[i].position = PLAYLIST_INSERT; 186 args[i].position = PLAYLIST_INSERT;
189 args[i].queue = false; 187 args[i].queue = false;
190 i++; 188 i++;
191 189
192 items[i].desc = str(LANG_INSERT_FIRST); 190 items[i].desc = ID2P(LANG_INSERT_FIRST);
193 items[i].voice_id = LANG_INSERT_FIRST;
194 args[i].position = PLAYLIST_INSERT_FIRST; 191 args[i].position = PLAYLIST_INSERT_FIRST;
195 args[i].queue = false; 192 args[i].queue = false;
196 i++; 193 i++;
197 194
198 items[i].desc = str(LANG_INSERT_LAST); 195 items[i].desc = ID2P(LANG_INSERT_LAST);
199 items[i].voice_id = LANG_INSERT_LAST;
200 args[i].position = PLAYLIST_INSERT_LAST; 196 args[i].position = PLAYLIST_INSERT_LAST;
201 args[i].queue = false; 197 args[i].queue = false;
202 i++; 198 i++;
203 199
204 items[i].desc = str(LANG_QUEUE); 200 items[i].desc = ID2P(LANG_QUEUE);
205 items[i].voice_id = LANG_QUEUE;
206 args[i].position = PLAYLIST_INSERT; 201 args[i].position = PLAYLIST_INSERT;
207 args[i].queue = true; 202 args[i].queue = true;
208 i++; 203 i++;
209 204
210 items[i].desc = str(LANG_QUEUE_FIRST); 205 items[i].desc = ID2P(LANG_QUEUE_FIRST);
211 items[i].voice_id = LANG_QUEUE_FIRST;
212 args[i].position = PLAYLIST_INSERT_FIRST; 206 args[i].position = PLAYLIST_INSERT_FIRST;
213 args[i].queue = true; 207 args[i].queue = true;
214 i++; 208 i++;
215 209
216 items[i].desc = str(LANG_QUEUE_LAST); 210 items[i].desc = ID2P(LANG_QUEUE_LAST);
217 items[i].voice_id = LANG_QUEUE_LAST;
218 args[i].position = PLAYLIST_INSERT_LAST; 211 args[i].position = PLAYLIST_INSERT_LAST;
219 args[i].queue = true; 212 args[i].queue = true;
220 i++; 213 i++;
@@ -222,8 +215,7 @@ static bool playlist_options(void)
222 else if (((selected_file_attr & TREE_ATTR_MASK) == TREE_ATTR_MPA) || 215 else if (((selected_file_attr & TREE_ATTR_MASK) == TREE_ATTR_MPA) ||
223 (selected_file_attr & ATTR_DIRECTORY)) 216 (selected_file_attr & ATTR_DIRECTORY))
224 { 217 {
225 items[i].desc = str(LANG_INSERT); 218 items[i].desc = ID2P(LANG_INSERT);
226 items[i].voice_id = LANG_INSERT;
227 args[i].position = PLAYLIST_INSERT; 219 args[i].position = PLAYLIST_INSERT;
228 args[i].queue = false; 220 args[i].queue = false;
229 i++; 221 i++;
@@ -419,8 +411,7 @@ int onplay(char* file, int attr)
419 411
420 if (!(attr & ATTR_DIRECTORY)) 412 if (!(attr & ATTR_DIRECTORY))
421 { 413 {
422 items[i].desc = str(LANG_ONPLAY_OPEN_WITH); 414 items[i].desc = ID2P(LANG_ONPLAY_OPEN_WITH);
423 items[i].voice_id = LANG_ONPLAY_OPEN_WITH;
424 items[i].function = list_viewers; 415 items[i].function = list_viewers;
425 i++; 416 i++;
426 } 417 }
@@ -429,35 +420,30 @@ int onplay(char* file, int attr)
429 (attr & ATTR_DIRECTORY) || 420 (attr & ATTR_DIRECTORY) ||
430 ((attr & TREE_ATTR_MASK) == TREE_ATTR_M3U)) 421 ((attr & TREE_ATTR_MASK) == TREE_ATTR_M3U))
431 { 422 {
432 items[i].desc = str(LANG_PLAYINDICES_PLAYLIST); 423 items[i].desc = ID2P(LANG_PLAYINDICES_PLAYLIST);
433 items[i].voice_id = LANG_PLAYINDICES_PLAYLIST;
434 items[i].function = playlist_options; 424 items[i].function = playlist_options;
435 i++; 425 i++;
436 } 426 }
437 427
438 items[i].desc = str(LANG_RENAME); 428 items[i].desc = ID2P(LANG_RENAME);
439 items[i].voice_id = LANG_RENAME;
440 items[i].function = rename_file; 429 items[i].function = rename_file;
441 i++; 430 i++;
442 431
443 if (!(attr & ATTR_DIRECTORY)) 432 if (!(attr & ATTR_DIRECTORY))
444 { 433 {
445 items[i].desc = str(LANG_DELETE); 434 items[i].desc = ID2P(LANG_DELETE);
446 items[i].voice_id = LANG_DELETE;
447 items[i].function = delete_file; 435 items[i].function = delete_file;
448 i++; 436 i++;
449 } 437 }
450 else 438 else
451 { 439 {
452 items[i].desc = str(LANG_DELETE_DIR); 440 items[i].desc = ID2P(LANG_DELETE_DIR);
453 items[i].voice_id = LANG_DELETE_DIR;
454 items[i].function = delete_dir; 441 items[i].function = delete_dir;
455 i++; 442 i++;
456 } 443 }
457 } 444 }
458 445
459 items[i].desc = str(LANG_CREATE_DIR); 446 items[i].desc = ID2P(LANG_CREATE_DIR);
460 items[i].voice_id = LANG_CREATE_DIR;
461 items[i].function = create_dir; 447 items[i].function = create_dir;
462 i++; 448 i++;
463 449