tag/Handler: convert to class with virtual methods
This commit is contained in:
@@ -414,16 +414,14 @@ faad_stream_decode(DecoderClient &client, InputStream &is)
|
||||
}
|
||||
|
||||
static bool
|
||||
faad_scan_stream(InputStream &is,
|
||||
const TagHandler &handler, void *handler_ctx) noexcept
|
||||
faad_scan_stream(InputStream &is, TagHandler &handler) noexcept
|
||||
{
|
||||
auto result = faad_get_file_time(is);
|
||||
if (!result.first)
|
||||
return false;
|
||||
|
||||
if (!result.second.IsNegative())
|
||||
tag_handler_invoke_duration(handler, handler_ctx,
|
||||
SongTime(result.second));
|
||||
handler.OnDuration(SongTime(result.second));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user