seiike cant even add a shadow 😭

This commit is contained in:
cranci1 2025-06-18 11:02:15 +02:00
parent baa42e643c
commit 7957601814

View file

@ -1357,6 +1357,12 @@ class CustomMediaPlayerViewController: UIViewController, UIGestureRecognizerDele
airplayButton.setContentCompressionResistancePriority(.required, for: .horizontal) airplayButton.setContentCompressionResistancePriority(.required, for: .horizontal)
controlsContainerView.addSubview(airplayButton) controlsContainerView.addSubview(airplayButton)
airplayButton.layer.shadowColor = UIColor.black.cgColor
airplayButton.layer.shadowOffset = CGSize(width: 0, height: 2)
airplayButton.layer.shadowOpacity = 0.6
airplayButton.layer.shadowRadius = 4
airplayButton.layer.masksToBounds = false
guard AVPictureInPictureController.isPictureInPictureSupported() else { guard AVPictureInPictureController.isPictureInPictureSupported() else {
return return
} }
@ -1368,7 +1374,6 @@ class CustomMediaPlayerViewController: UIViewController, UIGestureRecognizerDele
pipController = AVPictureInPictureController(playerLayer: pipPlayerLayer) pipController = AVPictureInPictureController(playerLayer: pipPlayerLayer)
pipController?.delegate = self pipController?.delegate = self
let config = UIImage.SymbolConfiguration(pointSize: 15, weight: .medium) let config = UIImage.SymbolConfiguration(pointSize: 15, weight: .medium)
let Image = UIImage(systemName: "pip", withConfiguration: config) let Image = UIImage(systemName: "pip", withConfiguration: config)
pipButton = UIButton(type: .system) pipButton = UIButton(type: .system)
@ -1416,11 +1421,11 @@ class CustomMediaPlayerViewController: UIViewController, UIGestureRecognizerDele
menuButton.isHidden = true menuButton.isHidden = true
} }
dismissButton.layer.shadowColor = UIColor.black.cgColor menuButton.layer.shadowColor = UIColor.black.cgColor
dismissButton.layer.shadowOffset = CGSize(width: 0, height: 2) menuButton.layer.shadowOffset = CGSize(width: 0, height: 2)
dismissButton.layer.shadowOpacity = 0.6 menuButton.layer.shadowOpacity = 0.6
dismissButton.layer.shadowRadius = 4 menuButton.layer.shadowRadius = 4
dismissButton.layer.masksToBounds = false menuButton.layer.masksToBounds = false
controlsContainerView.addSubview(menuButton) controlsContainerView.addSubview(menuButton)
menuButton.translatesAutoresizingMaskIntoConstraints = false menuButton.translatesAutoresizingMaskIntoConstraints = false