diff options
author | Jonathan Gordon <rockbox@jdgordon.info> | 2009-04-06 00:39:43 +0000 |
---|---|---|
committer | Jonathan Gordon <rockbox@jdgordon.info> | 2009-04-06 00:39:43 +0000 |
commit | 843c7efaf8c953fc3bec40a7da0be3a5da9950df (patch) | |
tree | cb27e411394f716d26193433c66132072730ea70 /apps/plugin.h | |
parent | 9188f0ffd7ce97101a5b2d697cc43072cd63b502 (diff) | |
download | rockbox-843c7efaf8c953fc3bec40a7da0be3a5da9950df.tar.gz rockbox-843c7efaf8c953fc3bec40a7da0be3a5da9950df.zip |
FS9795 - some playback cleanup.
* Use events to notify things when the track has changed instead of the nasty has_track_changed()
* Event for when the mp3entry for the next track is avilable (which allows alot more tags to be static which means less redrawing in the WPS)
* virtually guarentee that the mp3entry sturct returned by audio_current/next_track() is going to be valid for the duration of the current track. The only time it wont be now is during the time between the codec finishing the previous track and the next track actually starting (~2s), but this is not an issue as long as it is called again when the TRACK_CHANGED event happens (or just use the pointer that gives)
It is still possible to confuse the WPS with the next tracks id3 info being displayed but this should fix itself up faster than it used to (and be harder to do)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20633 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugin.h')
-rw-r--r-- | apps/plugin.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/plugin.h b/apps/plugin.h index 8954373d23..fdcf3c2afa 100644 --- a/apps/plugin.h +++ b/apps/plugin.h | |||
@@ -128,12 +128,12 @@ void* plugin_get_buffer(size_t *buffer_size); | |||
128 | #define PLUGIN_MAGIC 0x526F634B /* RocK */ | 128 | #define PLUGIN_MAGIC 0x526F634B /* RocK */ |
129 | 129 | ||
130 | /* increase this every time the api struct changes */ | 130 | /* increase this every time the api struct changes */ |
131 | #define PLUGIN_API_VERSION 146 | 131 | #define PLUGIN_API_VERSION 147 |
132 | 132 | ||
133 | /* update this to latest version if a change to the api struct breaks | 133 | /* update this to latest version if a change to the api struct breaks |
134 | backwards compatibility (and please take the opportunity to sort in any | 134 | backwards compatibility (and please take the opportunity to sort in any |
135 | new function which are "waiting" at the end of the function table) */ | 135 | new function which are "waiting" at the end of the function table) */ |
136 | #define PLUGIN_MIN_API_VERSION 146 | 136 | #define PLUGIN_MIN_API_VERSION 147 |
137 | 137 | ||
138 | /* plugin return codes */ | 138 | /* plugin return codes */ |
139 | enum plugin_status { | 139 | enum plugin_status { |
@@ -588,7 +588,6 @@ struct plugin_api { | |||
588 | void (*audio_ff_rewind)(long newtime); | 588 | void (*audio_ff_rewind)(long newtime); |
589 | struct mp3entry* (*audio_next_track)(void); | 589 | struct mp3entry* (*audio_next_track)(void); |
590 | int (*audio_status)(void); | 590 | int (*audio_status)(void); |
591 | bool (*audio_has_changed_track)(void); | ||
592 | struct mp3entry* (*audio_current_track)(void); | 591 | struct mp3entry* (*audio_current_track)(void); |
593 | void (*audio_flush_and_reload_tracks)(void); | 592 | void (*audio_flush_and_reload_tracks)(void); |
594 | int (*audio_get_file_pos)(void); | 593 | int (*audio_get_file_pos)(void); |