Skip to content

Commit 69d0ff5

Browse files
committed
Remove scroll directives from the source
1 parent 25e00f9 commit 69d0ff5

1 file changed

Lines changed: 0 additions & 50 deletions

File tree

src/datetime-range.js

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -173,53 +173,3 @@ angular.module('g1b.datetime-range', []).
173173
}
174174
};
175175
}]);
176-
177-
// Scroll up directive
178-
angular.module('g1b.datetime-range').
179-
directive('scrollUp', function () {
180-
return {
181-
restrict: 'A',
182-
compile: function () {
183-
return {
184-
pre: function preLink() {},
185-
post: function postLink(scope, element, attrs) {
186-
element.bind('mousewheel wheel', function (ev) {
187-
ev = ev.originalEvent || ev;
188-
var delta = ev.wheelDelta || (-1 * ev.deltaY) || 0;
189-
if ( delta > 0 ) {
190-
scope.$apply(function () {
191-
scope.$eval(attrs.scrollUp);
192-
});
193-
ev.preventDefault();
194-
}
195-
});
196-
}
197-
};
198-
}
199-
};
200-
});
201-
202-
// Scroll down directive
203-
angular.module('g1b.datetime-range').
204-
directive('scrollDown', function () {
205-
return {
206-
restrict: 'A',
207-
compile: function () {
208-
return {
209-
pre: function preLink() {},
210-
post: function postLink(scope, element, attrs) {
211-
element.bind('mousewheel wheel', function (ev) {
212-
ev = ev.originalEvent || ev;
213-
var delta = ev.wheelDelta || (-1 * ev.deltaY) || 0;
214-
if ( delta < 0 ) {
215-
scope.$apply(function () {
216-
scope.$eval(attrs.scrollDown);
217-
});
218-
ev.preventDefault();
219-
}
220-
});
221-
}
222-
};
223-
}
224-
};
225-
});

0 commit comments

Comments
 (0)