12345678910111213141516171819202122232425262728 |
- 'use strict';
- /**
- * Licensed Materials - Property of IBM
- * IBM Cognos Products: BI Cloud (C) Copyright IBM Corp. 2014, 2017
- * US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- */
- define(['../../lib/@waca/core-client/js/core-client/ui/core/Class'], function (Class) {
- var MouseWheel = null;
- MouseWheel = Class.extend({
- iOffset: 44, //Wheel scroll increment
- getOffset: function getOffset(oEvent) {
- var iDir;
- if (oEvent.type === 'DOMMouseScroll') {
- iDir = oEvent.originalEvent.detail > 0 ? 1 : -1;
- } else if (oEvent.type === 'wheel') {
- iDir = oEvent.originalEvent.deltaX > 0 ? 1 : -1;
- } else {
- iDir = oEvent.originalEvent.wheelDelta > 0 ? -1 : 1;
- }
- return this.iOffset * iDir;
- }
- });
- return new MouseWheel();
- });
- //# sourceMappingURL=MouseWheel.js.map
|