Closed marginTop closed 8 years ago
/** * Add scenes to the head of the data datasheets * * @param {Object|Array} sceneData * @description * Object: * {content:...} * Array: * [{content:...}, {content:...}, ...] */ iSliderPrototype.unshiftData = function (sceneData) { if (!sceneData) { return; } if (!isArray(sceneData)) { sceneData = [sceneData]; } var n = sceneData.length; this.data = sceneData.concat(this.data); if (this.slideIndex === 0) { this._renderItem(this.els[0], n - 1); } this.slideIndex += n; };