diff options
author | Nils Wallménius <nils@rockbox.org> | 2008-08-15 08:27:39 +0000 |
---|---|---|
committer | Nils Wallménius <nils@rockbox.org> | 2008-08-15 08:27:39 +0000 |
commit | 01729e7a1841d8aae7be37707dbc7146348c9a64 (patch) | |
tree | 5490fd9eccdcaef39bbbb91e8a44d1caad9b2ef7 /apps/plugins/wavplay.c | |
parent | 9464fdde2d780206e1eddba8cafbfbd4bbff83e4 (diff) | |
download | rockbox-01729e7a1841d8aae7be37707dbc7146348c9a64.tar.gz rockbox-01729e7a1841d8aae7be37707dbc7146348c9a64.zip |
FS#9281 Rename of splash functions.
* Remove gui_splash()
* Rename gui_syncsplash() to splashf() and remove its voice
capabilities.
* Rename the internal splash() to splash_internal() and introduce an
externally visible splash() that handles simple splashing without
printf functionality e.g. splash(HZ, ID2P(LANG_FOO)); or splash(HZ,
"foo"); if a LANG_* id is passed it will be voiced.
* Adjust all places that called gui_syncsplash() to use the correct
variant from above.
* Export both new functions to plugins and adjust places calling
rb->splash() to use the correct variant so that we now have naming
consistency between the core and plugins.
* Fix one latent bug that would cause my sim to crash with the above
changes and correct P2STR and P2ID macros, thanks to pondlife.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18282 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/wavplay.c')
-rw-r--r-- | apps/plugins/wavplay.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/plugins/wavplay.c b/apps/plugins/wavplay.c index 0a1136a6c2..333d16135c 100644 --- a/apps/plugins/wavplay.c +++ b/apps/plugins/wavplay.c | |||
@@ -3500,7 +3500,7 @@ int play_file(char* filename) | |||
3500 | format = letoh16(*(uint16_t *)(aud_buf + 20)); | 3500 | format = letoh16(*(uint16_t *)(aud_buf + 20)); |
3501 | if (format != 1) | 3501 | if (format != 1) |
3502 | { | 3502 | { |
3503 | rb->splash(2*HZ, "Unsupported format: %d", format); | 3503 | rb->splashf(2*HZ, "Unsupported format: %d", format); |
3504 | rb->close(fd); | 3504 | rb->close(fd); |
3505 | return PLAY_ERROR; | 3505 | return PLAY_ERROR; |
3506 | } | 3506 | } |
@@ -3508,7 +3508,7 @@ int play_file(char* filename) | |||
3508 | channels = letoh16(*(uint16_t *)(aud_buf + 22)); | 3508 | channels = letoh16(*(uint16_t *)(aud_buf + 22)); |
3509 | if (channels > 2) | 3509 | if (channels > 2) |
3510 | { | 3510 | { |
3511 | rb->splash(2*HZ, "Too many channels: %d", channels); | 3511 | rb->splashf(2*HZ, "Too many channels: %d", channels); |
3512 | rb->close(fd); | 3512 | rb->close(fd); |
3513 | return PLAY_ERROR; | 3513 | return PLAY_ERROR; |
3514 | } | 3514 | } |
@@ -3516,7 +3516,7 @@ int play_file(char* filename) | |||
3516 | samplebits = letoh16(*(uint16_t *)(aud_buf + 34)); | 3516 | samplebits = letoh16(*(uint16_t *)(aud_buf + 34)); |
3517 | if (samplebits != 16) | 3517 | if (samplebits != 16) |
3518 | { | 3518 | { |
3519 | rb->splash(2*HZ, "Unsupported sample depth: %dbit", samplebits); | 3519 | rb->splashf(2*HZ, "Unsupported sample depth: %dbit", samplebits); |
3520 | rb->close(fd); | 3520 | rb->close(fd); |
3521 | return PLAY_ERROR; | 3521 | return PLAY_ERROR; |
3522 | } | 3522 | } |
@@ -3534,7 +3534,7 @@ int play_file(char* filename) | |||
3534 | case 44100: rate = 9; break; | 3534 | case 44100: rate = 9; break; |
3535 | case 48000: rate = 10; break; | 3535 | case 48000: rate = 10; break; |
3536 | default: | 3536 | default: |
3537 | rb->splash(2*HZ, "Unsupported samplerate: %dHz", samplerate); | 3537 | rb->splashf(2*HZ, "Unsupported samplerate: %dHz", samplerate); |
3538 | rb->close(fd); | 3538 | rb->close(fd); |
3539 | return PLAY_ERROR; | 3539 | return PLAY_ERROR; |
3540 | } | 3540 | } |