Advertisement
Guest User

Untitled

a guest
Aug 17th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Swift 0.97 KB | None | 0 0
  1.     func setupModalTextCard() {
  2.        
  3.         selectCardViewController = SelectCardViewController(nibName:"SelectCardViewController", bundle:nil)
  4.         // Remove selectCardViewController from editorVC
  5.         selectCardViewController.removeFromParent()
  6.         selectCardViewController.view.removeFromSuperview()
  7.        
  8.         textCardViewController = TextCardViewController(nibName: "TextCardViewController", bundle:nil)
  9.         self.addChild(textCardViewController)
  10.         textCardViewController.view.layer.cornerRadius = 9
  11.         self.view.addSubview(textCardViewController.view)
  12.        
  13.         cardHandleOriginY = textCardViewController.handleArea.frame.origin.y
  14.  
  15.         textCardViewController.view.frame = CGRect(x: 0, y: self.view.frame.height - cardHandleOriginY - textCardHandleAreaHeight, width: self.view.bounds.width, height: textCardHeight)
  16.        
  17.         textCardViewController.view.clipsToBounds = true
  18.         print(#function)
  19.        
  20.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement