hide media when in show animation

This commit is contained in:
nixzhu
2015-06-17 16:51:39 +08:00
parent 60ef3a6a42
commit 1c021befcc
2 changed files with 6 additions and 1 deletions
-1
View File
@@ -239,7 +239,6 @@ class MediaPreviewView: UIView {
self.initialframe = initialframe
frame = initialframe
layoutIfNeeded()
UIView.animateWithDuration(0.25, delay: 0.0, options: .CurveEaseOut, animations: { _ in
+6
View File
@@ -35,8 +35,14 @@ class MediaView: UIView {
coverImageView.image = coverImage
coverImageView.alpha = 1
bringSubviewToFront(coverImageView)
scrollView.alpha = 0
videoPlayerLayer.opacity = 0
} else {
scrollView.alpha = 1
videoPlayerLayer.opacity = 1
UIView.animateWithDuration(0.05, delay: 0.0, options: .CurveLinear, animations: { _ in
self.coverImageView.alpha = 0
}, completion: { finished in