(scroller, options)
| 768 | }); |
| 769 | //Indicator |
| 770 | var Indicator = function(scroller, options) { |
| 771 | this.wrapper = typeof options.el == 'string' ? document.querySelector(options.el) : options.el; |
| 772 | this.wrapperStyle = this.wrapper.style; |
| 773 | this.indicator = this.wrapper.children[0]; |
| 774 | this.indicatorStyle = this.indicator.style; |
| 775 | this.scroller = scroller; |
| 776 | |
| 777 | this.options = $.extend({ |
| 778 | listenX: true, |
| 779 | listenY: true, |
| 780 | fade: false, |
| 781 | speedRatioX: 0, |
| 782 | speedRatioY: 0 |
| 783 | }, options); |
| 784 | |
| 785 | this.sizeRatioX = 1; |
| 786 | this.sizeRatioY = 1; |
| 787 | this.maxPosX = 0; |
| 788 | this.maxPosY = 0; |
| 789 | |
| 790 | if (this.options.fade) { |
| 791 | this.wrapperStyle['webkitTransform'] = this.scroller.translateZ; |
| 792 | this.wrapperStyle['webkitTransitionDuration'] = this.options.fixedBadAndorid && $.os.isBadAndroid ? '0.001s' : '0ms'; |
| 793 | this.wrapperStyle.opacity = '0'; |
| 794 | } |
| 795 | } |
| 796 | Indicator.prototype = { |
| 797 | handleEvent: function(e) { |
| 798 |
nothing calls this directly
no outgoing calls
no test coverage detected