code: function waitAndAdvance(step, steps) {
      setTimeout(function(){
        if (step < steps - 1) {
          api.next();
          waitAndAdvance(step+1, steps);
        }
        else {
          // after 15 seconds on last slide, exit fullscreen
          if(document.cancelFullScreen) {
            document.cancelFullScreen();
          } else if(document.mozCancelFullScreen) {
            document.mozCancelFullScreen();
          } else if(document.webkitCancelFullScreen) {
            document.webkitCancelFullScreen();
          }
        }
      }, slideAdvance);
    }
docs: recursive function to wait seconds before advancing