This was filed as a doc bug (see linked issue) with the justification that this was the expected behavior on iOS. However, the Android behavior does not match--blur and focus are fired on the window when the app is paused and restarted.
Before we address this in docs, I think we need an architectural decision on the correct behavior.
- Original Bug Description
Issue of the customer:
It seems the focus event does not get called on the active tab window when an app is resumed.
1.I load my app, and the window in tab 1 triggers on the focus event
2.I then background my app, without leaving this window
3.I then move the app back to the foreground. Even though the window now has focus, the focus event is not fired.
Is this by design or an issue? It seems that the focus event should fire as it is receiving focus again.
Summarized reply from platform team:
This is the expected behavior, it is by design. When you put an app into background, it is using the underlying pause/resume feature of iOS, this causes the 'focus' event not to trigger when you put it back into the foreground.
Reason why I created this ticket:
This isn't documented anywhere, at least I was unable to find anything when searching the wiki. It would be nice if this would be documented somewhere and easy to find, for future reference.