fix: Use new image in main menu

Resolves: https://gitlab.steamware.net/eqn/eqn.ios/-/issues/12
This commit is contained in:
Andrea Busi
2020-08-29 17:49:17 +02:00
parent 31f928fed9
commit 8d0439f7f8
2 changed files with 6 additions and 1 deletions
@@ -10,6 +10,7 @@ import UIKit
class MenuHeaderTableViewCell: UITableViewCell {
@IBOutlet weak var appIconImageView: UIImageView!
@IBOutlet weak var appVersionLabel: UILabel!
@IBOutlet weak var appIdLabel: UILabel!
@@ -20,7 +21,7 @@ class MenuHeaderTableViewCell: UITableViewCell {
// add a gradient for the background
let gradient = CAGradientLayer()
let blueColor = UIColor(red: 0.47, green: 0.72, blue: 0.98, alpha: 1.0)
let blueColor = UIColor(red: 131.0/255.0, green: 200.0/255.0, blue: 255.0/255.0, alpha: 1.0)
gradient.frame = bounds
gradient.colors = [ blueColor.cgColor, UIColor.white.cgColor ]
layer.insertSublayer(gradient, at: 0)
@@ -36,5 +37,8 @@ class MenuHeaderTableViewCell: UITableViewCell {
let userId = EQNUser.default().user_ID ?? "n.d."
appIdLabel.text = "ID: \(userId)"
let image = EQNPurchaseUtility.isProVersionEnabled() ? UIImage(named: "eq_icon_pro")! : UIImage(named: "eq_icon")!
appIconImageView.image = image
}
}