Friends,
I was testing my app on iPad3.2. It was running well.Then I tested the same binary in iPad 4.2.1,It shows Memory warning Level-1 in a seconds after I open the app (Before i make my first touch on the screen after Startup).
I just added a splitviewcontroller which has one tableView as MasterView( with just 10rows,no images) and on开发者_开发百科e UIWebview (just empty webview,simply initialized,NO urls loaded) .neither images nor graphic contents were loaded at the start up.
I guess, RAM was occupied by the Apps that are running in background (Yes, i had 20 apps in background). I get no memory warnings at startup if I close all the apps manually.
But, Still..... I cant ask my user to quit other apps before running my app.
1.Can anyone suggest me any workaround??
2.Is there any possibility to free the RAM memory occupied (by other apps) ?
3.If i keep on visting web pages(with larger images) in my app, i get memory warnings and it crashes..But if i repeat the same set of pages in Safari Browser ,(or in some other apps too), it doesn't crash!! how can I render efficiently? I dont find any options like that in UIWebView Class!!
Any answers/hints will be more appreciated...
Thanks in advance. Gopi
When your app needs memory, and memory is low, the OS seems to send a memory warning to ALL running apps, including those in the background and yours. If you are not using a lot of memory, ignore the first warning, and wait a few run loop ticks. Hopefully one of the other background apps will release some memory. If enough memory isn't released, the OS will kill an app, possibly yours, but more likely, if your app isn't a memory hog, an app in the background.
精彩评论