We have an application that gets installed with badge and also configured over badge. The badge sends some arguments with the instalation and the application generates its config file if it does not exist. This worked great, but now we had to make a change, so that not only the first time the application should check to browser invoke event, but actually every time, it is started over web.
The problem is that we add the NativeApplication.nativeApplication.addEventListener(BrowserInvokeEvent.BROWSER_INVOKE at the beginig of application, but the event handler isn't executed until so late in application, that all other initialization is done (INVOKE handler, config loader). At that point the only thing we could do is restart the application.
My quiestion is. How to reliably wait for the browser invoke event, if possible not on timer. If the application was not run over badge, we want to start normaly as soon as possible.
To whom it may concern.
Invoke and browser_invoke handlers should be regisered only after loaderInfo COMPLE event is fired. Also know that uncaughtErrorEvents UNCAUGHT_ERROR will work after the COMPLETE wvent fires.