0

I want to add shadows to views, each in a table view's content view, but as soon as I do the UI becomes incredibly unresponsive and laggy.

Does anyone know a better way to draw shadows than this:

mainView.layer.shadowColor = UIColor.blackColor().CGColor
mainView.layer.shadowOffset = CGSize(width: 0.5, height: 0.5)
mainView.layer.shadowOpacity = 0.3
mainView.clipsToBounds = false
mainView.layer.masksToBounds = false        
mainView.layer.shadowRadius = 2
Petri
  • 1,020
  • 3
  • 14
  • 24

0 Answers0