|
@@ -14,7 +14,7 @@ class PQStuckPointMusicContentCell: UICollectionViewCell {
|
|
|
var contentType: stuckPointMusicContentType = .catagery
|
|
|
|
|
|
lazy var audioImageView: UIImageView = {
|
|
|
- let audioImageView = UIImageView(image: UIImage(named: "videomk_music_default"))
|
|
|
+ let audioImageView = UIImageView(image: UIImage.init().BF_Image(named: "videomk_music_default"))
|
|
|
audioImageView.addCorner(corner: 4)
|
|
|
audioImageView.contentMode = .scaleAspectFill
|
|
|
return audioImageView
|
|
@@ -29,7 +29,7 @@ class PQStuckPointMusicContentCell: UICollectionViewCell {
|
|
|
|
|
|
lazy var playImageView: UIImageView = {
|
|
|
let playImageView = UIImageView()
|
|
|
- playImageView.image = UIImage(named: "stuckPoint_music_pause")
|
|
|
+ playImageView.image = UIImage.init().BF_Image(named: "stuckPoint_music_pause")
|
|
|
return playImageView
|
|
|
}()
|
|
|
|
|
@@ -114,16 +114,16 @@ class PQStuckPointMusicContentCell: UICollectionViewCell {
|
|
|
musicNameLab.isHidden = !(bgmData is PQVoiceModel)
|
|
|
titleLab.isHidden = (bgmData is PQVoiceModel)
|
|
|
if bgmData is PQVoiceModel {
|
|
|
- audioImageView.setNetImage(url: "\((bgmData as? PQVoiceModel)?.avatarUrl ?? "")", placeholder: UIImage(named: "videomk_music_default")!)
|
|
|
+ audioImageView.setNetImage(url: "\((bgmData as? PQVoiceModel)?.avatarUrl ?? "")", placeholder: UIImage.init().BF_Image(named: "videomk_music_default"))
|
|
|
confirmContentView.isHidden = !((bgmData as? PQVoiceModel)?.isSelected ?? false)
|
|
|
if (bgmData as? PQVoiceModel)?.isSelected ?? false {
|
|
|
playImageView.isHidden = false
|
|
|
if (bgmData as? PQVoiceModel)?.isPlaying ?? false {
|
|
|
playImageView.image = nil
|
|
|
- playImageView.kf.setImage(with: URL(fileURLWithPath: Bundle.main.path(forResource: "stuckPoint_music_playing", ofType: ".gif")!))
|
|
|
+ playImageView.kf.setImage(with: URL(fileURLWithPath: Bundle.init().BF_mainbundle().path(forResource: "stuckPoint_music_playing", ofType: ".gif")!))
|
|
|
musicNameLab.move()
|
|
|
} else {
|
|
|
- playImageView.image = UIImage(named: "stuckPoint_music_pause")
|
|
|
+ playImageView.image = UIImage.init().BF_Image(named: "stuckPoint_music_pause")
|
|
|
musicNameLab.stop()
|
|
|
}
|
|
|
} else {
|
|
@@ -132,10 +132,12 @@ class PQStuckPointMusicContentCell: UICollectionViewCell {
|
|
|
musicNameLab.stop()
|
|
|
}
|
|
|
} else {
|
|
|
+
|
|
|
+
|
|
|
if (bgmData as? PQStuckPointMusicTagsModel)?.tagEmoji != nil {
|
|
|
- audioImageView.setNetImage(url: "\((bgmData as? PQStuckPointMusicTagsModel)?.tagEmoji ?? "")", placeholder: UIImage(named: "videomk_music_default")!)
|
|
|
+ audioImageView.setNetImage(url: "\((bgmData as? PQStuckPointMusicTagsModel)?.tagEmoji ?? "")", placeholder: UIImage.init().BF_Image(named: "videomk_music_default"))
|
|
|
} else {
|
|
|
- audioImageView.image = UIImage(named: "videomk_music_default")
|
|
|
+ audioImageView.image = UIImage.init().BF_Image(named: "videomk_music_default")
|
|
|
}
|
|
|
titleLab.text = " \((bgmData as? PQStuckPointMusicTagsModel)?.tagName ?? "")"
|
|
|
if (titleLab.text?.count ?? 0) > 8 {
|