show keyboard and push view about.

NSNotificationCenter.defaultCenter().addObserver(self, selector: #selector(PetEditViewController.keyboardWillShow(_:)), name: UIKeyboardWillShowNotification, object: nil)
NSNotificationCenter.defaultCenter().addObserver(self, selector: #selector(PetEditViewController.keyboardWillHide(_:)), name: UIKeyboardWillHideNotification, object: nil)

automaticallyAdjustsScrollViewInsets = false

func keyboardWillShow(notification: NSNotification) {
if !keyboardUp {
UIView.animateWithDuration(0.25) {
self.view.center = CGPoint(x: self.view.center.x, y: self.view.center.y - 100)
}
keyboardUp = true
}
}

func keyboardWillHide(notification: NSNotification) {
if keyboardUp {
UIView.animateWithDuration(0.25) {
self.view.center = CGPoint(x: self.view.center.x, y: self.view.center.y + 100)
}
keyboardUp = false
}
}