diff options
author | Jean-Philippe Bernardy <jeanphilippe.bernardy@gmail.com> | 2005-02-09 10:56:54 +0000 |
---|---|---|
committer | Jean-Philippe Bernardy <jeanphilippe.bernardy@gmail.com> | 2005-02-09 10:56:54 +0000 |
commit | 0f6b3796d6143f36300e7f3136ba4ad73ab41913 (patch) | |
tree | cf8ce408c184dbfcada9f78015df8c686e7b3616 /apps/bookmark.c | |
parent | c1d7708dfa2ba5ad8417aa0513b0b052fdfece4d (diff) | |
download | rockbox-0f6b3796d6143f36300e7f3136ba4ad73ab41913.tar.gz rockbox-0f6b3796d6143f36300e7f3136ba4ad73ab41913.zip |
long policy
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5863 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/bookmark.c')
-rw-r--r-- | apps/bookmark.c | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/apps/bookmark.c b/apps/bookmark.c index 969371eeeb..e96561319b 100644 --- a/apps/bookmark.c +++ b/apps/bookmark.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /*************************************************************************** | 1 | /*************************************************************************** |
2 | * __________ __ ___. | 2 | * __________ __ ___. |
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | 3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ |
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | 4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / |
@@ -6,7 +6,7 @@ | |||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | 6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ |
7 | * \/ \/ \/ \/ \/ | 7 | * \/ \/ \/ \/ \/ |
8 | * | 8 | * |
9 | * Copyright (C) 2003 by Benjamin Metzler | 9 | * Copyright (C)2003 by Benjamin Metzler |
10 | * | 10 | * |
11 | * All files in this archive are subject to the GNU General Public License. | 11 | * All files in this archive are subject to the GNU General Public License. |
12 | * See the file COPYING in the source tree root for full license agreement. | 12 | * See the file COPYING in the source tree root for full license agreement. |
@@ -70,7 +70,7 @@ static bool parse_bookmark(const char *bookmark, | |||
70 | int *resume_first_index, | 70 | int *resume_first_index, |
71 | char* resume_file, | 71 | char* resume_file, |
72 | unsigned int resume_file_size, | 72 | unsigned int resume_file_size, |
73 | int* ms, | 73 | long* ms, |
74 | int * repeat_mode, | 74 | int * repeat_mode, |
75 | bool *shuffle, | 75 | bool *shuffle, |
76 | char* file_name); | 76 | char* file_name); |
@@ -778,7 +778,7 @@ static void display_bookmark(const char* bookmark, | |||
778 | int bookmark_count) | 778 | int bookmark_count) |
779 | { | 779 | { |
780 | int resume_index = 0; | 780 | int resume_index = 0; |
781 | int ms = 0; | 781 | long ms = 0; |
782 | int repeat_mode = 0; | 782 | int repeat_mode = 0; |
783 | bool playlist_shuffle = false; | 783 | bool playlist_shuffle = false; |
784 | int len; | 784 | int len; |
@@ -834,19 +834,20 @@ static void display_bookmark(const char* bookmark, | |||
834 | /* elapsed time*/ | 834 | /* elapsed time*/ |
835 | if ( ms < 3600000 ) | 835 | if ( ms < 3600000 ) |
836 | { | 836 | { |
837 | snprintf(global_temp_buffer, sizeof(global_temp_buffer), "%s: %d:%02d", | 837 | snprintf(global_temp_buffer, sizeof(global_temp_buffer), "%s: %ld:%02d", |
838 | str(LANG_BOOKMARK_SELECT_TIME_TEXT), | 838 | str(LANG_BOOKMARK_SELECT_TIME_TEXT), |
839 | ms / 60000, | 839 | ms / 60000, |
840 | ms % 60000 / 1000); | 840 | (unsigned int)(ms % 60000) / 1000); |
841 | /* unsigned int: hinting for 16bits archs */ | ||
841 | } | 842 | } |
842 | else | 843 | else |
843 | { | 844 | { |
844 | snprintf(global_temp_buffer, sizeof(global_temp_buffer), | 845 | snprintf(global_temp_buffer, sizeof(global_temp_buffer), |
845 | "%s: %d:%02d:%02d", | 846 | "%s: %ld:%02ld:%02d", |
846 | str(LANG_BOOKMARK_SELECT_TIME_TEXT), | 847 | str(LANG_BOOKMARK_SELECT_TIME_TEXT), |
847 | ms / 3600000, | 848 | ms / 3600000, |
848 | ms % 3600000 / 60000, | 849 | ms % 3600000 / 60000, |
849 | ms % 60000 / 1000); | 850 | (unsigned int)(ms % 60000) / 1000); |
850 | } | 851 | } |
851 | lcd_puts_scroll(0, 3, global_temp_buffer); | 852 | lcd_puts_scroll(0, 3, global_temp_buffer); |
852 | 853 | ||
@@ -900,7 +901,7 @@ static void say_bookmark(const char* bookmark, | |||
900 | int bookmark_id) | 901 | int bookmark_id) |
901 | { | 902 | { |
902 | int resume_index; | 903 | int resume_index; |
903 | int ms; | 904 | long ms; |
904 | char dir[MAX_PATH]; | 905 | char dir[MAX_PATH]; |
905 | bool enqueue = false; /* only the first voice is not queued */ | 906 | bool enqueue = false; /* only the first voice is not queued */ |
906 | 907 | ||
@@ -987,7 +988,7 @@ static bool parse_bookmark(const char *bookmark, | |||
987 | int *resume_first_index, | 988 | int *resume_first_index, |
988 | char* resume_file, | 989 | char* resume_file, |
989 | unsigned int resume_file_size, | 990 | unsigned int resume_file_size, |
990 | int* ms, | 991 | long* ms, |
991 | int * repeat_mode, bool *shuffle, | 992 | int * repeat_mode, bool *shuffle, |
992 | char* file_name) | 993 | char* file_name) |
993 | { | 994 | { |