Duplicate Show Hide Spinner calls.
Duplicate Show Hide Spinner calls.
One thing I have notice in past few weeks is that when I doing any multiple rest service call, busy indicator hide way too early. I dig around js source code which found that inside mobilebase.js, we have subscribed ajax's start and stop event to fire show and hide indicator, but inside tiggzi.js, we still register numbers of those show and hide action in different place. Result early hidespinner call.
Something even worse is that it even doing show and hide on send and complete event while already registered for ajax's start and stop event.
I have comment out send and complete function's show and hide action which still not hide too early, at end I comment out all show and hide method from tiggzi.js and purely rely on ajax's event which end up rather perfect.
I know there are case that not belong to ajax which need busy indicator, but register so many event will cause a lot of issue. It will be good if left show and hide action as optional instead of build in function. Or put it inside one of action inside event list.
When project is simple you won't notice difference, but when project getting larger and complex, it's really not good idea to handle show and hide at tiggzi side.