         self.addSubview(self.titleLabel)
         self.addSubview(self.subtitleLabel)
         self.addSubview(self.imageView)
+        
+        
+        // Gestures
+        let tap = UITapGestureRecognizer(target: self, action: #selector(RNNotificationView.didTap(_:)))
+        self.addGestureRecognizer(tap)
+        let pan = UIPanGestureRecognizer(target: self, action: #selector(RNNotificationView.didPan(_:)))
+        self.addGestureRecognizer(pan)
         
         // Setup frames
         self.setupFrames()

        }
    }
    private var verticalPositionConstraint: NSLayoutConstraint!
//    private var tapAction = #selector(NotificationView.notificationViewTapped)

    
    private lazy var imageView: UIImageView = {
        let imageView = UIImageView()
//        imageView.translatesAutoresizingMaskIntoConstraints = false // auto-layout only

            completion?()

        }
    }
    
    
    @objc private func didTap(gesture: UIGestureRecognizer) {
        self.userInteractionEnabled = false
        self.hide(completion: self.tapAction)
    }

    @objc private func didPan(gesture: UIPanGestureRecognizer) {
        
        switch gesture.state {
        case .Ended:
            self.isDragging = false
            if frame.origin.y < 0 || self.duration <= 0 {
                self.hide(completion: nil)
            }
            break
            
        case .Began:
            self.isDragging = true
            break

        case .Changed:
            
            guard let superview = self.superview else {
                return
            }
            
            guard let gestureView = gesture.view else {
                return
            }
            
            let translation = gesture.translationInView(superview)
            // Figure out where the user is trying to drag the view.
            let newCenter = CGPoint(x: superview.bounds.size.width / 2,
                                    y: gestureView.center.y + translation.y)
            
            // See if the new position is in bounds.
            if (newCenter.y >= (-1 * NotificationLayout.height / 2) && newCenter.y <= NotificationLayout.height / 2) {
                gestureView.center = newCenter
                gesture.setTranslation(CGPoint.zero, inView: superview)
            }

            break

        default:
            break
        }
        
    }

    
}

