mirror of
https://github.com/Hopiu/angular.js.git
synced 2026-03-16 23:30:23 +00:00
refactor($animate): speed up animationsDisabled check
This commit is contained in:
parent
1df3da361d
commit
5cfacec499
1 changed files with 2 additions and 0 deletions
|
|
@ -754,6 +754,8 @@ angular.module('ngAnimate', ['ng'])
|
|||
}
|
||||
|
||||
function animationsDisabled(element, parentElement) {
|
||||
if (rootAnimateState.disabled) return true;
|
||||
|
||||
if(element[0] == $rootElement[0]) {
|
||||
return rootAnimateState.disabled || rootAnimateState.running;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue