File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -224,10 +224,10 @@ angular.module('ui.scroll', [])
224224
225225 $scope . $on ( '$destroy' , ( ) => {
226226 unbindEvents ( ) ;
227- viewport . unbind ( 'mousewheel' , wheelHandler ) ;
227+ viewport . off ( 'mousewheel' , wheelHandler ) ;
228228 } ) ;
229229
230- viewport . bind ( 'mousewheel' , wheelHandler ) ;
230+ viewport . on ( 'mousewheel' , wheelHandler ) ;
231231
232232 initialize ( ) ;
233233
@@ -238,13 +238,13 @@ angular.module('ui.scroll', [])
238238 }
239239
240240 function bindEvents ( ) {
241- viewport . bind ( 'resize' , resizeAndScrollHandler ) ;
242- viewport . bind ( 'scroll' , resizeAndScrollHandler ) ;
241+ viewport . on ( 'resize' , resizeAndScrollHandler ) ;
242+ viewport . on ( 'scroll' , resizeAndScrollHandler ) ;
243243 }
244244
245245 function unbindEvents ( ) {
246- viewport . unbind ( 'resize' , resizeAndScrollHandler ) ;
247- viewport . unbind ( 'scroll' , resizeAndScrollHandler ) ;
246+ viewport . off ( 'resize' , resizeAndScrollHandler ) ;
247+ viewport . off ( 'scroll' , resizeAndScrollHandler ) ;
248248 }
249249
250250 function reload ( ) {
You can’t perform that action at this time.
0 commit comments