NumbersTableViewCell.swift
1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
//
// NumbersTableViewCell.swift
// SwiftWarplyFramework
//
// Created by Manos Chorianopoulos on 15/7/22.
//
import UIKit
@objc public class NumbersTableViewCell: UITableViewCell {
@IBOutlet weak var numberLabel: UILabel!
@IBOutlet weak var borderView: UIView!
public override func awakeFromNib() {
super.awakeFromNib()
// Initialization code
}
public override func setSelected(_ selected: Bool, animated: Bool) {
super.setSelected(selected, animated: animated)
// Configure the view for the selected state
}
// override func layoutSubviews() {
// super.layoutSubviews()
//
// //set the values for top,left,bottom,right margins
// let margins = UIEdgeInsets(top: 0, left: 0, bottom: 30, right: 0)
// contentView.frame = contentView.frame.inset(by: margins)
// }
func configureCell(number: String, isLast: Bool) {
numberLabel.text = number
if (isLast) {
borderView.isHidden = true
} else {
borderView.isHidden = false
}
}
}