Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Medium
-
Resolution: Won't Fix
-
Affects Version/s: None
-
Fix Version/s: 2013 Sprint 04 API, 2013 Sprint 04
-
Component/s: TiAPI
Description
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.
For example:
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.
Attached sample code to reproduce this issue:
app.js: http://pastebin.com/1x8KJNXL
test.js: http://pastebin.com/ShaypcYE
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.
Attachments
Issue Links
- is cloned from
-
TIDOC-626 iOS: Couldn't find documentation about why 'focus' event on window is not called after resume
-
- Closed
-
- is included by
-
TIMOB-10373 TiAPI: event system: Event ordering
-
- Open
-
- relates to
-
TIMOB-10373 TiAPI: event system: Event ordering
-
- Open
-