Open e1ernal opened 1 month ago
extension UINavigationController { func hideHairline() { if let hairline = findHairlineImageViewUnder(navigationBar) { hairline.isHidden = true } } func restoreHairline() { if let hairline = findHairlineImageViewUnder(navigationBar) { hairline.isHidden = false } } func findHairlineImageViewUnder(_ view: UIView) -> UIImageView? { if view is UIImageView && view.bounds.size.height <= 1.0 { return view as? UIImageView } for subview in view.subviews { if let imageView = self.findHairlineImageViewUnder(subview) { return imageView } } return nil } }
Добавить выбор типа новостей Horizontal Slide Menu в NavigationItem