Injections not working in AIR release build
Hi,
I've been having trouble getting injection to work in AIR (at least versions 2.5 and 2.6). It all works fine from Flash Builder, but when I create a release build, the injections do not work.
In order to test this, I created a basic project, with a main view, a child view, mediators for both and a context. I then added an actor, which I inject into both the mediators. In the onRegister methods of the mediators, I check for the existence of the actor, and output the result to a text field. From Flash Builder, it's all fine, but in the release version, the injected actors are both null.
I thought it might be delayed, so I added an enterframe and a try/catch to keep checking for their existence, but nada.
Anyone have any ideas how to get around this?
Owen
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Stray on 25 May, 2011 08:45 PM
Hi Owen, is your metadata definitely being kept by FlashBuilder? When you're building from swc it will be kept in test builds by default, but not release builds.
Check out the "Common problems" document for more info.
Stray
2 Posted by Owen on 25 May, 2011 08:54 PM
That was it exactly! Thanks (again) Stray :)
Owen
3 Posted by Stray on 25 May, 2011 08:59 PM
No worries!
Stray closed this discussion on 29 May, 2011 06:46 PM.