File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -77,6 +77,8 @@ function explode() {
7777 return ;
7878 }
7979
80+ var execTime = new ExecutionTime ( ) ;
81+ execTime . start ( ) ;
8082
8183 var hideShyLayers_originalState = selectedLayer . containingComp . hideShyLayers ;
8284 selectedLayer . containingComp . hideShyLayers = true ;
@@ -86,6 +88,9 @@ function explode() {
8688 selectedLayer . moveToBeginning ( )
8789 selectedLayer . containingComp . hideShyLayers = hideShyLayers_originalState ;
8890
91+ execTime . stop ( ) ;
92+ cLog ( execTime . time ( ) ) ;
93+
8994}
9095
9196function emptyDuplicateLayer ( layer ) {
Original file line number Diff line number Diff line change @@ -18,3 +18,26 @@ function listMatchNames(object) {
1818 }
1919
2020}
21+
22+ function ExecutionTime ( ) {
23+
24+ var startTime ;
25+ var endTime ;
26+ var execTime ;
27+
28+ this . constructor = function ( ) { }
29+
30+ this . start = function ( ) {
31+ startTime = new Date ( ) . getTime ( ) ;
32+ }
33+
34+ this . stop = function ( ) {
35+ endTime = new Date ( ) . getTime ( )
36+ execTime = endTime - startTime ;
37+ }
38+
39+ this . time = function ( ) {
40+ return 'Execution time : ' + Math . floor ( execTime / 1000 ) + 's ' + ( execTime % 1000 ) + 'ms' ;
41+ }
42+
43+ }
You can’t perform that action at this time.
0 commit comments