Question

Today I encountered this bug:

http://bugs.adobe.com/jira/browse/SDK-26147

I am loading another team's application via SWFLoader into my own application. For various reasons, I must use the flag loadForCompatibility and set it to true. I have noticed that ALL the spark DropDownList instances in the loaded sub-application offset their dropdowns incorrectly. Since my application has a header, the pulldowns are offset vertically by the height of the header. MX versions of ComboBox in a test sub-application do not have this problem.

I tried adding the line:

-includes=mx.managers.systemClasses.MarshallingSupport

and

-includes+=mx.managers.systemClasses.MarshallingSupport

to my Application's compiler options but it has no effect.

I also noticed, when trying to write an import statement, that MarshallingSupport doesn't even exist. I am using FlashBuilder 4. I am using the default SDK (4.1). The sub-application is the same.

Is there any kind of workaround for this? Am I doing something wrong? Why must this be? Telling the other team to switch all their s:DropDownList to mx:ComboBox is going to be onerous to say the least. It will also be very time consuming since the APIs are different. I really hope there is something I can do to solve this problem. Please tell me I am doing it wrong.

Was it helpful?

Solution

Ok, so one option was to make a new DropdownListSkin that modified the behavior of AnchorPopUp. That was an ok solution. But it turns out with some more struggling, I got "-includes+=mx.managers.systemClasses.MarshallingSupport" to finally work in the compiler. I was able to confirm whether marshalling support was on or off by putting a break point at line 1432 of MatrixUtil.getConcatenatedMatrixHelper(). Or, alternatively you can check by calling:

 ApplicationDomain.currentDomain.hasDefinition("mx.managers.systemClasses.MarshallingSupport");

So if like me you think you have your compiler options set correctly, use the above code to confirm that you really actually honest-to-god have it right. As long as MatrixUtil can access MarshallingSupport, then your spark pulldowns, etc. will work fine.

Furthermore, I got some help from the Adobe forums: http://forums.adobe.com/thread/1034957

edit: I am flagging this as an answer so SO will stop asking me to accept an answer.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top