Nicer toolbar buttons

This commit is contained in:
James Magahern
2020-08-14 15:55:08 -07:00
parent 9b36a3ace5
commit 69029a3195
12 changed files with 534 additions and 187 deletions

View File

@@ -24,6 +24,7 @@ class URLBar: UIView
}
private let backgroundView = UIVisualEffectView(effect: UIBlurEffect(style: .systemThickMaterial))
private let shadowView = UIView(frame: .zero)
private let progressIndicatorView = ProgressIndicatorView()
private let fadeMaskView = UIImageView(frame: .zero)
@@ -40,7 +41,7 @@ class URLBar: UIView
backgroundView.layer.masksToBounds = true
backgroundView.layer.cornerRadius = backgroundCornerRadius
backgroundView.layer.borderWidth = 1
backgroundView.layer.borderColor = UIColor.systemFill.cgColor
backgroundView.layer.borderColor = UIColor.secondarySystemFill.cgColor
backgroundView.isUserInteractionEnabled = false
addSubview(backgroundView)
@@ -166,6 +167,7 @@ class URLBar: UIView
override func layoutSubviews() {
super.layoutSubviews()
backgroundView.frame = bounds
shadowView.frame = bounds
progressIndicatorView.frame = backgroundView.contentView.bounds
textField.frame = bounds.insetBy(dx: 6.0, dy: 0)