dojo.connect(map, "onUpdateEnd", updateEnd);
So I did
map.on("onUpdateEnd", hideLoading") (on line 60 of attached file)
but the hideLoading is never triggered. Should I do it on a layer instead of layer? Thanks!