Commit ec93256e6bf8b41917ca702999cea1d35ba4dd0e

Authored by “张旭”
1 parent a807b4fc

下滑页-推荐块的圆角

metaCode/Classes/Main/HomePage/View/VerticalViews/DownSlide/CNLiveDownSlideRecommendCell.swift
... ... @@ -31,6 +31,7 @@ class CNLiveDownSlideRecommendCell: UITableViewCell {
31 31 super.init(style: style, reuseIdentifier: reuseIdentifier)
32 32 self.selectionStyle = .none
33 33 contentView.backgroundColor = HexColor(kCNDownSlideBackgroundColorHex)
  34 + contentView.clipsToBounds = true
34 35 }
35 36  
36 37 required init?(coder: NSCoder) {
... ... @@ -58,6 +59,8 @@ class CNLiveDownSlideRecommendCell: UITableViewCell {
58 59 let imageView = UIImageView(frame: CGRectMake(DownSlideRecommendLeftGap, CGFloat(hangIndex-1)*DownSlideRecommendWH+DownSlideRecommendLeftGap*CGFloat(hangIndex-1), CGFloat(DownSlideRecommendWH), CGFloat(DownSlideRecommendWH)))
59 60 imageView.kf.setImage(with: URL(string:contentMdl.poster!))
60 61 imageView.tag = i
  62 + imageView.layer.cornerRadius = 14
  63 + imageView.clipsToBounds = true
61 64 imageView.isUserInteractionEnabled = true
62 65 imageView.addGestureRecognizer(UITapGestureRecognizer.init(target: self, action: #selector(pushWebAction)))
63 66 contentView.addSubview(imageView)
... ... @@ -68,6 +71,8 @@ class CNLiveDownSlideRecommendCell: UITableViewCell {
68 71 let imageView = UIImageView(frame: CGRectMake(CGFloat(DownSlideRecommendLeftGap*2)+CGFloat(DownSlideRecommendWH), CGFloat(hangIndex-1)*DownSlideRecommendWH+DownSlideRecommendLeftGap*CGFloat(hangIndex-1), CGFloat(DownSlideRecommendWH), CGFloat(DownSlideRecommendWH)))
69 72 imageView.kf.setImage(with: URL(string:contentMdl.poster!))
70 73 imageView.tag = i
  74 + imageView.layer.cornerRadius = 14
  75 + imageView.clipsToBounds = true
71 76 imageView.isUserInteractionEnabled = true
72 77 imageView.addGestureRecognizer(UITapGestureRecognizer.init(target: self, action: #selector(pushWebAction)))
73 78 contentView.addSubview(imageView)
... ...
metaCode/Classes/Main/HomePage/View/VerticalViews/DownSlide/CNLiveDownSlideTodayRecommendCell.swift
... ... @@ -32,6 +32,7 @@ class CNLiveDownSlideTodayRecommendCell: UITableViewCell {
32 32 super.init(style: style, reuseIdentifier: reuseIdentifier)
33 33 self.selectionStyle = .none
34 34 contentView.backgroundColor = HexColor(kCNDownSlideBackgroundColorHex)
  35 + contentView.clipsToBounds = true
35 36 }
36 37  
37 38 required init?(coder: NSCoder) {
... ...