ABMediaView v0.4.2 Release Notes
Release Date: 2017-07-07 // almost 6 years ago-
โ Added:
- Setting the 'shouldDismissAfterFinish' variable on a mediaView will have it dismiss after it finished playing its video. This value take precedence over 'allowLooping' when mediaView is fullscreen.
- Utilize the 'mediaViewDidFinishVideo:withLooping' delegate method to take action after a mediaView has completed playing of its video. This delegate also lets you know whether the mediaView will loop (this delegate is called before the video loops).
โก๏ธ Updated:
- ๐ Moved the following variables to public read-only so that they can be utilized:
- 'minViewHeight' is the width the mediaView will be when fully minimized
- 'minViewHeight' is the height the mediaView will be when fully minimized
- 'maxViewOffset' is the maximum space between the top of the mediaView and the top of its superview, when fully minimized
- 'offsetPercentage' is the fraction (0 to 1) by which the mediaView has completed minimization
- 'superviewWidth' is the width of view which presents the mediaView
- 'superviewHeight' is the height of view which presents the mediaView
- Tune ups for caching
Previous changes from v0.4.1
-
Released : 3/4/17
โ Added:
- Automated Caching for Images, GIFs and Videos, enabled by setting the variable 'setShouldCacheMedia' on the ABMediaView sharedManager.
- Ability to preload video and audio before being shown by calling 'preloadVideo' or 'preloadAudio' on a mediaView, or automatically handled by setting 'shouldPreloadVideoAndAudio' variable on the ABMediaView sharedManager.
- Ability to clear Documents directory and tmp directory cached files, by calling 'clearABMediaDirectory' class method of ABMediaView and providing one of the following:
- 'VideoDirectoryItems' to remove cached videos on disk loaded from ABMediaView
- 'AudioDirectoryItems' to remove cached audio on disk loaded from ABMedaiView
- 'AllDirectoryItems' to remove cached videos and audio on disk loaded from ABMedaiView
- 'TempDirectoryItems' to remove cached files in tmp directory folder
- Functionality to not have a play button be visible by setting 'playButtonHidden' on the ABMediaView. Usefull if one is looking to use ABMediaView in a video background.
- โ Tests added for loading and caching data.
โก๏ธ Updated
- ๐ Media is checked to see if proper format is received from NSURL before downloading.
- ๐ Adjusted the following loader functions to seperate loading with a NSString and loading from a given NSURL (useful if specifying loading media from a location not on the web). Functions are available in ABCacheManager.
- 'loadImage' with NSString, 'loadImageURL' with NSURL
- 'loadVideo' with NSString, 'loadVideoURL' with NSURL
- 'loadAudio' with NSString, 'loadAudioURL' with NSURL
- 'loadGIF' with NSString, 'loadGIFURL' with NSURL
- Detects if the video/audio failed to load, and shows a failed indicator. A custom failed indicator can be set with 'setCustomFailedButton' on the ABMediaView.
- ๐ 'hideCloseButton' was changed to 'closeButtonHidden' to match the new 'playButtonHidden' variable better.
- ๐ 'videoIndicator' (the view which held the play button image) was changed to 'playIndicatorView' to better encompass that it is visible when both video and audio is in the mediaView.
๐ Fixed
- Media looking to be downloaded from ipod-library is now properly loaded and cached is specified.
- AVURLAsset in export video method changed to AVAsset,