]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commit
fixes mutateme.zf.trigger fires as often as many submenu you got because it's in... 9948/head
authorjk <j.koehler@modulingo.de>
Tue, 11 Apr 2017 18:25:57 +0000 (20:25 +0200)
committerjk <j.koehler@modulingo.de>
Tue, 11 Apr 2017 18:25:57 +0000 (20:25 +0200)
commitf1786b2b21f0f76a3b5d59d04c88ec0455514d87
treecfe10946a12505a0e6943246fb32ddf1b7d1656d
parent92e89a6c542c8d647daf28663d1c36f2b42299d1
fixes mutateme.zf.trigger fires as often as many submenu you got because it's in the _events($elem) function, and this gets bound as manu times you got submenues.

i'got a menu with 92 submenu's and wondered why the performance is so weak on clicking on the responsiveToggle, so i started searching an found that the mutateme event gets fired as many times as there are submenus, and on the drilldown then 92 times the _getMaxDims was executedthis calcs the heights and so on and is very performant, so i debugged it an moved it to the _registerEvents function

big performance improvement
js/foundation.drilldown.js