docs: function () {
                  var options = autoScroll.interaction.target.options[autoScroll.interaction.prepared.name].autoScroll,
                      container = options.container || getWindow(autoScroll.interaction.element),
                      now = new Date().getTime(),
                      // change in time in seconds
                      dtx = (now - autoScroll.prevTimeX) / 1000,
                      dty = (now - autoScroll.prevTimeY) / 1000,
                      vx, vy, sx, sy;
  
                  // displacement
                  if (options.velocity) {
                    vx = options.velocity.x;
                    vy = options.velocity.y;
                  }
                  else {
                    vx = vy = options.speed
                  }
   
                  sx = vx * dtx;
                  sy = vy * dty;
  
                  if (sx >= 1 || sy >= 1) {
                      if (isWindow(container)) {
                          container.scrollBy(autoScroll.x * sx, autoScroll.y * sy);
                      }
                      else if (container) {
                          container.scrollLeft += autoScroll.x * sx;
                          container.scrollTop  += autoScroll.y * sy;
                      }
  
                      if (sx >=1) autoScroll.prevTimeX = now;
                      if (sy >= 1) autoScroll.prevTimeY = now;
                  }
  
                  if (autoScroll.isScrolling) {
                      cancelFrame(autoScroll.i);
                      autoScroll.i = reqFrame(autoScroll.scroll);
                  }
              }