Valid AS3 will crash iPhone app on startup

Steps to reproduce:
1. Add this code to a Flex Mobile Project:
        public class Foo extends EventDispatcher {
             public override function addEventListener(type:String,  listener:Function, useCapture:Boolean=false, priority:int=0,  useWeakReference:Boolean=false):void {
                 var thisFunc:Function= arguments.callee;
                 super.addEventListener(type, listener, useCapture, priority, useWeakReference);
2. Refer to the class Foo somewhere in the application, for example the creation complete handler of MainHomeView.mxml:
        protected function view1_creationCompleteHandler(event:FlexEvent):void {
             var foo:Foo;
3. Debug this on an iOS device using the 'Standard' packaging method.  Also, you could export a Release build for iOS.
When the iOS app launches, it will crash before running any code  written by the programmer-- just the *presence* of this code in the app  causes it to crash (!).  I'm attaching a crash log.
I've filed a bug for this here: https://bugs.adobe.com/jira/browse/FB-32130

Hi,
im using Flash Builder 4.6  in a mobile project.
Hhis cause a crash, can't see  nothing than the splash screen:
public static function getInstance():ApplicationData {
            if (!ApplicationData.instance){
                ApplicationData.instance = new ApplicationData(arguments.callee);
            return ApplicationData.instance;
private var applicationData:ApplicationData = ApplicationData.getInstance();
Is there any solution?
Thanks

Similar Messages

  • Using box2d flash as3 engine for iphone apps

    Hi
    have any body tried box2d flash as3 libraries working with flsh cs5 iphone apps.? when i compile app it give many errors, using flash player 9 give one error b2fixture undefined type error. any body developing physics base games as3 for iphone please share any good as3 physics base game engine.
    Thanks

    If you are targeting all iDevices I strongly suggest to forget about the Box2D. There is absolutely no way you can get (almost) any kind of physics simulation running smoothly with 1st and 2nd generation iDevices with current version of Packager for iPhone.
    And it really is graphics that is the problem more than anything else. Forget about caching Sprites or MovieClips. Actually don't use MovieClips and Sprites at all, it's just too slow. Instead start extending Bitmap class with your own animation system (swapping BitmapData) and mouse handling (hitTestPoint), there's plenty of examples.
    And then if you write really really optimized code you can get one fluently moving and animated sprite object running on your iPhone or iPhone 3G (with out doing anything else than just moving and animating that one object). More than one (animated and/or moving) object causes serious performance problems. You don't notice this as linear slowing in FPS (which would still be kind of ok), but it's more like skipping frames every now and then. This looks and feels really disturbing and makes designing of games pretty hard...Using GPU mode doesn't make any difference.
    But to answer the question, I'm pretty convinced that you can get (simple) Box2D simulation running smoothly on iPhone if you:
    1. Target only 3rd generation iDevices and above
    2. Use only Bitmaps as graphics
    3. Do rotations with pre-rendered frames (or don't use rotation at all)
    4. Optimize Box2D and your code thoroughly
    Just for **** and giggles I think I try to get some kind of physics simulation running on 3G too...
    By the way, comparing performance of 1st generation iPhone to HTC Desire (I happen to own both too) is like comparing C-64 to my shiny new Phenom II X6 rig. If you just look at the specs:
    HTC Desire:
    1 GH ARM v7
    AMD Z430 GPU
    576 Mb DRAM
    iPhone 3G:
    ARM 1176JZ(F)-S (underclocked to 412 MHz)
    PowerVR MBX Lite 3D
    128 Mb DRAM

  • Image capture will crash app (such as texting or Facebook)

    I have an iPhone 4S on the 7.0 iOS. Lately, anytime I take a photo with any photo app Isuch as texting, Facebook, check deposit etc.) besides the camera app will crash the app. What is the fix, please?
    Thanks

    Hello thirudoc,
    We've an article that provides a number of troubleshooting steps which may help get your camera working in other applications.
    Camera isn't functioning or has undesired image quality
    If the screen shows a closed lens or black image, force quit the Camera app.
    If you do not see the Camera app on the Home screen, try searching for it in Spotlight. If the camera does not show up in the search, check to make sure that Restrictions are not turned on by tappingSettings > General > Restrictions.
    Ensure the camera lens is clean and free from any obstructions. Use a microfiber polishing cloth to clean the lens.
    Cases can interfere with the camera and the flash. Try gently cleaning the lens with a clean dry cloth or removing the case if you see image or color-quality issues with photos.
    Try turning iPhone off and then back on.
    Tap to focus the camera on the subject. The image may pulse or briefly go in and out of focus as it adjusts.
    Try to remain steady while focusing:
    Still images: Remain steady while taking the picture. If you move too far in any direction, the camera automatically refocuses to the center.
    Note: If you take a picture with iPhone turned sideways, it is automatically saved in landscape orientation.
    Video: Adjust focus before you begin recording. You can also tap to readjust focus while recording. Exiting the Camera application while recording will stop recording and will save the video to the Camera Roll.
    Note: Video-recording features are not available on original iPhone or iPhone 3G.
    If your iPhone has a front and rear camera, try switching between them to verify if the issue persists on both.
    My issue is still not resolved. What do I do next?
    Contact Apple Support.
    iPhone: Hardware troubleshooting
    http://support.apple.com/kb/TS2802
    Cheers,
    Allen

  • What to do if iPhone apps don't work after syncing with iTunes

    Just wanting to share this with anyone who may have the same problem.
    This is what I did: All I did was authorised my computer to transfer apps into my iTunes.
    This may also help (depending on the cause of the problem)
    http://www.iphonealley.com/tips/how-to-fix-broken-or-crashing-iphone-apps
    (Thanks to Jim for sending this link but apparently my solution was a much simpler one)
    Hope this helps! Cheerios!

    Try this - worked for me:
    on the iPhone, go Settings-->General-->Restricitons and either turn all Restrictions off OR if they are on make sure 'Installing Apps' is ON.

  • Difference Between iPad and iPhone Apps

    hello all,
    Yet recently the new idevice was launched, However, prior to the launch of the ipad, the information that i had (which requires your updates) that iphone apps can too run on ipad too. As the ipad app store was launched later than the hardware.
    So, my question is, if i am planning to buy the ipad (which has been launched in india yesterday), will my iphone apps would run on the ipad, especially the games ?

    Almost everything that runs on the iPhone will run on the iPad. But in a small window that matches the number of pixels of a 3GS iPhone. You can double the pixels to get it to fit the screen, but some people don't like the pixelaton this causes.
    The only things that won't run are things like telephony or photo apps that require use of hardware not present on the current iPad.
    Jason

  • App build will crash on iphone 5s and wont on iphone 4

    so when i install the bulid on iphone 5s it will crash after opening and on iphone 4 i pretty stay there on for hrs.

    Hello kfarooq,
    Thanks for using Apple Support Communities.
    For more information on this, take a look at:
    iOS: Troubleshooting apps purchased from the App Store
    http://support.apple.com/kb/ts1702
    Best of luck,
    Mario

  • IPhone app crash diagnosis

    I have one user of my app who reports that she sees the default bitmap for 2-3 seconds and then goes straight back to the home screen: in other words, my app is silently terminating right at the start.
    Would a crash cause this - or would a crash also display some sort of error message?
    Is any diagnostic information extractable afterwards - even not-very-useful diagnostic information?
    (Fortunately it's a free app).

    You've got it right--your app is crashing on startup. It's probably generating a crash report, but I don't know what Apple does with them.
    Some things to think about:
    1. Does the user have a different device type? For example, does she have an iPod touch and you only tested with iPhones? Or the user has a 3G and you only tested with an EDGE model? Does the user have push Exchange enabled when you didn't in testing?
    2. How about languages and locales? Were there any background apps running and using resources, like iPod? Is there anything else odd about the device--is it unlocked or jailbroken, for example? (Jailbroken phones might have background apps using resources.)
    3. Look at your code closely. Are there any possible race conditions? (That's where two parts of the program are trying to operate on the same object at the same time, and depending on the order in which they get to act, the program will either succeed or crash.)
    4. Look very closely at how you use memory during initialization. In particular, try running your code under Guard Malloc; try it out with Instruments's leak-detection mode; and see if you can turn on zombie objects. Memory management bugs are a code smell; they often indicate deeper problems.
    5. If all else fails, just go ahead and refactor the code in your application's launch. No code is ever perfect, especially code in an iPhone app this close to the App Store's launch. Your spring cleaning might turn something up.

  • My IPAD 1 will after 1 min. crash in apps

    Hello People
    My IPAD will crash everitime after start e App, i can read papers for 30 sek. then the App will crash with an OS 4.x or 5.0

    If this happens with one particular app, delete the app by holding down the app icon until it jiggles then tap the circle with an x then tap Delete. Press the Home button once to stop the jiggling.
    Then restart your iPad. Hold the On/Off Sleep/Wake button down until the red slider appears. Slide your finger across the slider to turn off iPhone. To turn iPhone back on, press and hold the On/Off Sleep/Wake button until the Apple logo appears.

  • AS3 to develop a iPhone app

    Does anyone think this will ever be possible?  Is anyone working on something that would make this possible?  Is Adobe?  Would anyone else besides me like to use AS3 to create an iPhone app?

    i'd love to but i'm learning objective-c right now because i have a client that wants me to build some iphone apps.   it seems unlikely that apple would do anything to facilitate this.  they like controlling every aspect of their products.

  • My iPhone apps keep crashing a lot please help

    iphone apps keep crashing a lot and sometimes freeze in the middle please help what am I supposed to do
    to stop this?

    Try the standard troubleshooting steps in this order:
    Restart: Press On/Off button until the Slide to Power Off slider appears, select Slide to Power Off and, after It shuts down, press the On/Off button until the Apple logo appears.
    Reset: Press the Home and On/Off buttons at the same time and hold them until the Apple logo appears (about 10-15 seconds). No data will be lost.
    Restore: Connect your iPhone to iTunes on your computer, backup, and then select Restore to Factory.
    See here: Use iTunes to restore your iOS device to factory settings ...

  • HT204053 My new HK iPhone will not download apps purchased in U.S. and says I need an HK Apple ID.  This creates a second Apple ID and I am concerned that I will have to pay twice for the same app.

    My new HK iPhone will not download apps purchased in U.S. and says I need an HK Apple ID.  This creates a second Apple ID and I am concerned that I will have to pay twice for the same app.

    Apps previously purchased will continue to operate wherever you are.    However; you'll not be able to update them other than by using the original purchase details.   What this means is that you can only 'purchase' from a country's store if you have a valid credit card and residence of and in that country.

  • IPhone 4 intermittent crashes - Facebook app issue?

    My iPhone 4 rarely crashed before Sunday. The only thing that changed was I installed the latest Facebook app (with the Places feature). Since then, the phone will intermittently crash at random. I've noticed it crashes while in Messages, Mail, and iPod. When it crashes, it returns to the homescreen and I'm able to re-launch apps as normal.
    I notice this mostly in iPod, which I use a lot. While playing mid-song, iPod will crash. When I re-launch iPod, it will have returned to the beginning of the song that just crashed. At times it will crash in Messages while I'm composing a text. When I relaunch Messages, it returns me to the message stream I was in, but everything I have typed just before it crashed is lost.
    Strangely, it hasn't crashed on me while in the Facebook app. Not sure if the app has anything to do with this?
    After the crashing started, I upgraded to the latest version of iOS4, which I hadn't done yet. Didn't help. Have also tried numerous restarts, both hard and "soft."
    Any ideas? Makes using the phone a painful process. Before the iPhone 4, I had an original iPhone that never had crashing problems like this.

    The apps on my iPhone 4 have been crashing, as well. Tried all the restarts and reboots and nothing seems to help. The Best Buy app is what seems to crash on me a lot as well as games my son plays. Safari also crashes when scrolling down through long pages. Never had a problem before with iphone software. What was originally a minor annoyance is turning into an aggravating experience.

  • IPhone apps crashing & battery draining, why?

    My iPhone apps seem to be crashing after a few seconds including Music, email, facebook, sleepcycle and internet. My battery also seems to be draining really quickly all of a sudden. Today, my battery only lasted 4 hours without me using my phone! Has anyone else experienced this and knows of a fix?

    SuperSunT,  Thanks for posting this... as I'm having the same problem.
    Both my partner and I have iPhone 4S bought on the day they came out.  We weren't having any problems till last month I noticed my phone had the "lock" icon in the center at the top of the home screen and any apps (this "lock" icon is NOT the rotation lock, it is the one that should normally only show up when the phone is locked).  I could not get rid of it, no matter how many times I locked and unlocked my phone.  When I went to go to the Settings app/page, it was blank.  It was just a light grey background with tiny pinstripes (the usual background of the Settings page).   I was also unsuccessful turning the phone off just using the lock/power button.
    I finally had to hard-reset the phone as apps started to not work either. 
    I've only had the "lock" icon problem once, but I've had the Settings App/page blank several times, and each time I've then been unable to shut off the phone with just the lock/power button... then apps start to malfunction.
    The other day it did it and I just let it sit locked for about 10 minutes and it resolved.
    I have app crashes from time to time, but not anymore than before. 
    My partner's phone started having the Settings app/page being blank and being unable to shut off the phone wihtout a hard reset the other day as well! 
    I do not really want to do a clean install, and HATE when the Genius bar suggest this.  They don't ever suggest this for their Mac products, yet they're so nonchalant with this on the phone.  I know they're two VERY different products, but this is getting to be their "I don't know what's wrong.  Instead of me replacing your phone, you must drive back your hour drive, do this arbitrary thing which may or may not fix the problem, and when it doesn't, bring it back in so we can replace the phone and have it do the same thing again until an update comes out!" 
    Sorry, can you tell I've had a few too many problems where this is the case! 
    Anyway... I'm really curious about a few things.  I've not done a clean install since getting iOS 5 (even when I got the 4S I restored it from a 4 backup... but my partner just built his from scratch).  So, I know Game Center will take care of my games.  My e-mails are all stored on the server.  My notes are backed up to the Cloud.  I do have general Cloud backups turned off.  I know I'll need to transfer pictures.  But what other types of stuff do you suggest I should backup?  Basically, I'm asking what are the things you wished you had backed up that you forgot?
    And what is this "some apps let you send backups by email" that you speak of?  I've not seen that, but I've also not gone looking for it?  It drives me nuts that some apps have settings within the app, and some have them in the Settings app/page... and even worse, some have both! 
    Sorry this post is so long, but I've been searching for other people having these problems for a month now... starting with the "lock" icon problem (I figured that was the one identifying thing).  Unfortunately, I just ended up with hundreds of people who couldn't figure out that they had turned on the rotation lock and couldn't turn it back off.   
    Thanks for your (or anyone else's) help in advance! 
    P.S.  I'm including pictures of the "lock" problem as well as the blank Settings page! 
    This first one shows the "lock" icon at the top.  Clearly I am on the "Home" screen and the phone is not locked.
    This second one is while I'm in the Settings app.  This was taken the same day, and I just noticed that not only is the "lock" icon not showing, neither is the clock.  I have another screen shot from a different day where I wasn't getting the "lock" icon problem, but the clock was in the middle at the top as it should be. 

  • My iPhone was stolen a few days ago. It appears to be offline on the Find My iPhone app. If the person who has it turns it on only for a brief moment and then turns it off immediately, will the location still be found? Once it returns to be

    My iPhone was stolen a few days ago. It appears to be offline on the Find My iPhone app. If the person who has it turns it on only for a brief moment and then turns it off immediately, will the location still be found? Once it returns to being offline will the location still be sent to me? And also, how can I retrieve my pictures from my iCloud?

    Anything is possible.

  • HT203421 How do I get iphone apps in the mac app store? Also, my apps from my iphone will not sync to my mac. Why is this?

    I've had my iphone 4 for a couple years, but I've recently purchased a new macbook air. For some reason, I do not have the option of syncing my apps from my iphone to itunes. I am currently running ios 6 on my phone, but I don't want to update until the apps are backed up to the computer. How do I resolve this? Also, is there a way to download and/or update iphone apps from the mac app store?

    Connect the iPhone and iTunes will open automatically. Then, go to iTunes menu (on the menu bar) > Devices > Transfer purchases, and all the content downloaded from the App Store and the iTunes Store will be transferred to the MacBook. Note that in iTunes 11 you can choose the iPhone at the top right part of your iTunes window.
    The Mac App Store is used to download Mac OS X apps, and the App Store is used to download apps for iPod touch, iPad and iPhone. You can't download apps for iPhone from the Mac App Store. Instead, you can download them from iTunes or from the iPhone

Maybe you are looking for

  • Older magazine downloads disappear from 'Newstand'..

    Hi,   I am very sorry if this is the wrong area to post this question but I looked for a long time without being able to find an appropriate place to star this discussion. I am a current subscriber to Thrasher Skateboarding magazine, and WIRED magazi

  • Game center cannot invite friends...please help

    As the title says...myself and lot of friends cannot invite each other to play games...the wheel just spins and spins till you just have to cancel the invite...all notifications are on for inviting friends and games... No-one seems to know the answer

  • Content-Disposition - Dynamically set in Mail Adapter

    Hi All, I need to dynamically set the Content-Disposition in the receiver mail adapter so as to facilitate dynamic names for my attachment in the mail. In case i use messagetransform bean, I will have to hard code the name as part of the parameter va

  • File based Sync-Async Bridge

    Hi All, I have a scenario where a file is available in a shared folder. This file needs to be picked by a RFC Function module called in a Synchronous mode and the contents of the file needs to be displayed as the output of this RFC. Is this achievabl

  • Translate widget in Dashboard doesn't work

    I can choose the Translation widget in my Dashboard, however, I can't choose the languages (from/to) with the arrows.... :-(