code: function() {
        var shouldContinue = Math.abs(self.__decelerationVelocityX) >= self.__minVelocityToKeepDecelerating ||
          Math.abs(self.__decelerationVelocityY) >= self.__minVelocityToKeepDecelerating;
        if (!shouldContinue) {
          self.__didDecelerationComplete = true;
  
          //Make sure the scroll values are within the boundaries after a bounce,
          //not below 0 or above maximum
          if (self.options.bouncing && !self.__refreshActive) {
            self.scrollTo(
              Math.min( Math.max(self.__scrollLeft, 0), self.__maxScrollLeft ),
              Math.min( Math.max(self.__scrollTop, 0), self.__maxScrollTop ),
              self.__refreshActive
            );
          }
        }
        return shouldContinue;
      }
docs: Detect whether it's still worth to continue animating steps If we are already slow enough to not being user perceivable anymore, we stop the whole process here.