1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 |
- //
- // RankingListHeaderView.swift
- // xingchuangke
- //
- // Created by Virgil on 2019/4/17.
- // Copyright © 2019 Virgil. All rights reserved.
- //
- import UIKit
- class RankingListHeaderView: UIView {
- @IBOutlet weak var img1: UIImageView!
- @IBOutlet weak var img2: UIImageView!
- @IBOutlet weak var img3: UIImageView!
- @IBOutlet weak var lblName1: UILabel!
- @IBOutlet weak var lblName2: UILabel!
- @IBOutlet weak var lblName3: UILabel!
- @IBOutlet weak var lbl3: UILabel!
- @IBOutlet weak var lbl1: UILabel!
- @IBOutlet weak var lbl2: UILabel!
- @IBOutlet weak var viewTop3: UIView!
- @IBOutlet weak var viewTop2: UIView!
- @IBOutlet weak var viewTop1: UIView!
- @IBOutlet weak var lblTime: UILabel!
- func initView(strNames: [String], strIcons: [String]) {
- lblName1.text = strNames[0]
- lblName2.text = strNames[1]
- lblName3.text = strNames[2]
- lbl1.setCornerRadius()
- lbl2.setCornerRadius()
- lbl3.setCornerRadius()
- img1.loadImage(imgUrl: strIcons[0], defaultImage: "")
- img2.loadImage(imgUrl: strIcons[1], defaultImage: "")
- img3.loadImage(imgUrl: strIcons[2], defaultImage: "")
- img1.setLayer(borderWidth: 2, color: 0xfdc623)
- img2.setLayer(borderWidth: 2, color: 0xe0e1ea)
- img3.setLayer(borderWidth: 2, color: 0xd6a468)
- img1.setCornerRadius()
- img2.setCornerRadius()
- img3.setCornerRadius()
- }
- }
|