 
 import UIKit
 
-public protocol ABVideoRangeSliderDelegate: class {
+@objc public protocol ABVideoRangeSliderDelegate: class {
     func didChangeValue(videoRangeSlider: ABVideoRangeSlider, startTime: Float64, endTime: Float64)
     func indicatorDidChangePosition(videoRangeSlider: ABVideoRangeSlider, position: Float64)
+    
+    @objc optional func sliderGesturesBegan()
+    @objc optional func sliderGesturesEnded()
 }
 
-public class ABVideoRangeSlider: UIView {
+public class ABVideoRangeSlider: UIView, UIGestureRecognizerDelegate {
 
     private enum DragHandleChoice {
         case start

        return position
    }
    
    private func getPositionLimit(with drag: DragHandleChoice) -> CGFloat {
        if drag == .start {
            return positionFromValue(value: self.endPercentage - valueFromSeconds(seconds: self.minSpace))
        } else {
            return positionFromValue(value: valueFromSeconds(seconds: self.minSpace) + self.startPercentage)
        }
    }
    
    private func getPositionLimitMax(with drag: DragHandleChoice) -> CGFloat {
        if drag == .start {
            return positionFromValue(value: self.endPercentage - valueFromSeconds(seconds: self.maxSpace))
        } else {
            return positionFromValue(value: self.startPercentage + valueFromSeconds(seconds: self.maxSpace))
        }
    }
    

        var position = positionFromValue(value: self.progressPercentage)
        position = position + translation.x

        if position < positionLimitStart {
            position = positionLimitStart
        }

        if position > positionLimitEnd {
            position = positionLimitEnd
        }

