From 249aff6245f6b0c82b3b61f317025481953e9d0a Mon Sep 17 00:00:00 2001 From: Damiano Galassi Date: Thu, 12 Dec 2013 20:05:23 +0100 Subject: [PATCH] Add back a method that got lost in the google code -> bitbucket port. --- MP42/QTKitDecrap.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/MP42/QTKitDecrap.h b/MP42/QTKitDecrap.h index 01d65ae..a4cd4db 100644 --- a/MP42/QTKitDecrap.h +++ b/MP42/QTKitDecrap.h @@ -18,6 +18,19 @@ extern NSString * const QTTrackLanguageAttribute; // NSNumber (long) @end +@implementation QTMovie (QTMovieSublerExtras) + +- (QTTrack *)trackWithTrackID:(NSInteger)trackID +{ + for (QTTrack *track in [self tracks]) + if (trackID == [[track attributeForKey:QTTrackIDAttribute] integerValue]) + return track; + + return nil; +} + +@end + @interface QTMovie (QTMovie_MetadataReading_10_6_Fix) #if (defined(MAC_OS_X_VERSION_10_7))