mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-22 06:03:45 +00:00
Organic Maps sources as of 02.04.2025 (fad26bbf22ac3da75e01e62aa01e5c8e11861005)
To expand with full Organic Maps and Maps.ME commits history run: git remote add om-historic [om-historic.git repo url] git fetch --tags om-historic git replace squashed-history historic-commits
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
final class InfoTableViewCell: UITableViewCell {
|
||||
|
||||
private let infoView = InfoView()
|
||||
|
||||
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
|
||||
super.init(style: .default, reuseIdentifier: reuseIdentifier)
|
||||
setupView()
|
||||
}
|
||||
|
||||
@available(*, unavailable)
|
||||
required init?(coder: NSCoder) {
|
||||
super.init(coder: coder)
|
||||
setupView()
|
||||
}
|
||||
|
||||
private func setupView() {
|
||||
backgroundView = UIView() // Set background color to clear
|
||||
setStyle(.clearBackground)
|
||||
contentView.addSubview(infoView)
|
||||
infoView.translatesAutoresizingMaskIntoConstraints = false
|
||||
NSLayoutConstraint.activate([
|
||||
infoView.leadingAnchor.constraint(equalTo: contentView.leadingAnchor),
|
||||
infoView.trailingAnchor.constraint(equalTo: contentView.trailingAnchor),
|
||||
infoView.topAnchor.constraint(equalTo: contentView.topAnchor),
|
||||
infoView.bottomAnchor.constraint(equalTo: contentView.bottomAnchor),
|
||||
])
|
||||
}
|
||||
|
||||
// MARK: - Public
|
||||
func set(image: UIImage?, title: String) {
|
||||
infoView.set(image: image, title: title)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user