Has anyone recoded Apple's AVSimplePlayer example in Swift? I’m trying to do that in order to get some AVFoundation experience in Swift, and I’m having a bit of trouble. I can’t figure out how to do the bindings to currentTime and duration.
- If I do them the easy way, using didSet clause, everything works and I can play the video and use the Rewind and Fast Forward buttons to alter playback rate, but I can’t scrub using the time slider. - If I imitate the ObjC version and try to do the bindings in IB, the time slider’s maxValue and value bindings don’t work (won’t compile) because duration and currentTime are not NSNumbers. - And if I change duration and currentTime to computed variables based on NSNumber, the video won’t play at all. Any suggestions? -- Charles _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com