Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-4221] iOS: Memory Warnings Unload Tabs

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionCannot Reproduce
Resolution Date2011-09-01T15:01:13.000+0000
Affected Version/sRelease 1.7.0
Fix Version/sSprint 2011-21, Sprint 2011-35
ComponentsiOS
Labelsenterprise, ios, release-1.7.0
ReporterDawson Toth
AssigneeReggie Seagraves
Created2011-05-24T11:22:49.000+0000
Updated2017-03-28T17:12:58.000+0000

Description

Memory Warnings Unload Tabs

If you have a tab group with two active tabs, and a memory warning happens, the inactive tab will "Black Screen of Death".

Sample Code

var tabGroup = Ti.UI.createTabGroup();
tabGroup.addTab(Ti.UI.createTab({
    title: '4. Switch to Me',
    window: Ti.UI.createWindow({
        backgroundColor: 'purple',
        title: '1. Look at my BG Color'
    })
}));
tabGroup.addTab(Ti.UI.createTab({
    title: '2. Switch to Me',
    window: Ti.UI.createWindow({
        backgroundColor: 'orange',
        title: '3. Simulate a Memory Warning'
    })
}));
tabGroup.open();

How To Reproduce

Follow the steps on screen in the sample code (1 through 4). Generally, you'll do this:

Look at the purple background color of the first tab.

Click on the second tab.

Simulate a memory warning.

Switch back to the first tab.

Look at the black background -- the tab has been unloaded.

Console Log

2011-05-25 15:05:56.409 PlaygroundMobile[18905:40b] Received simulated memory warning.
[INFO] Due to memory conditions, 0 of 0 image cache entries were unloaded from cache.

Tested On

See environment.

Associated Helpdesk Ticket

http://appc.me/c/APP-241843

Attachments

FileDateSize
crash_log_1_8_run22011-08-26T17:17:42.000+0000104995
crash_log_1_8_run22011-08-26T17:17:29.000+0000104995
info vic events.zip2011-08-26T17:19:29.000+00002087319

Comments

  1. Dawson Toth 2011-05-25

    Editing the ticket now for additional clarity and reproducibility...
  2. Blain Hamon 2011-05-25

    Last remnants of the great Memory Change; Tab groups weren't remembering/forgetting tabs.
  3. Eric Merriman 2011-05-26

    THis is still failing in the simulator with Titanium Studio, build: 1.0.0.201105260623, Titanium SDK version: 1.7.X r5e4f9c7e
  4. Blain Hamon 2011-05-26

    We were prematurely unloading viewcontrollers.
  5. Asim Siddiqui 2011-08-26

    This issue was reproduced with 1.8 build on iPad 1 running iOS 4.3.5(8L1) version=1.8.0 timestamp=08/19/11 14:25 githash=56b54a2... Attaching Logs Attaching zip of application. To reproduce run many applications to take start taking up memory resources. Run the application and it will show a black screen and the logs show "unloading windows"
  6. Asim Siddiqui 2011-08-26

    Project Attached
  7. Reggie Seagraves 2011-09-01

    Shak, Please follow up with Asim on his further attachments to this issue, validate and open a new bug if necessary.
  8. Katsuma Ito 2011-10-31

    Reproduced with 1.7.4 release on iPod touch 4g (4.3.3) and iPhone Simulator (5.0) and iPhone4(4.3.2). Not with 1.7.3 release. 1.7.3.mov http://cl.ly/0a2H2R3o1W1G421K3D3v 1.7.4.mov http://cl.ly/3s3y3p3q2F1f19343F1U
  9. Jason Sznol 2012-01-06

  10. Stephen Tramer 2012-01-06

    This may not be reproducible in 1.8.0.1. Please upgrade your SDK and confirm that the bug is no longer present.
  11. Jason Sznol 2012-01-06

    This has been fixed in 1.8.0.1, we have been reluctant to upgrade due to other issues with the 1.8.0.1 release and our app.
  12. Neeraj Gupta 2012-01-06

    Correction: We continue to support 1.7.x release but we do not backport non critical issues to this branch. This particular fix is pretty involved and it would be better to upgrade to 1.8.0.1 release not only to get this fix but also to get many other fixes and enhancements.
  13. Thomas Huelbert 2012-02-09

    closing based on Steve's comments
  14. Lee Morris 2017-03-28

    Closing ticket with reference to the comments above.

JSON Source