// local2.registerInheritingStyle(local0); // local2 is the style manager.
// }
// }
if (isAppFlexInfo)
{
MethodInfo initMethodInfo = new MethodInfo();
initMethodInfo.setMethodName("FlexInit init method");
initMethodInfo.setParamTypes(new Vector<Name>(Collections.singleton(new Name("Object"))));
initMethodInfo.setReturnType(new Name(IASLanguageConstants.void_));
IMethodVisitor initMethodVisitor = emitter.visitMethod(initMethodInfo);
initMethodVisitor.visit();
MethodBodyInfo initMethodBodyInfo = new MethodBodyInfo();
initMethodBodyInfo.setMethodInfo(initMethodInfo);
IMethodBodyVisitor initMethodBodyVisitor = initMethodVisitor.visitBody(initMethodBodyInfo);
initMethodBodyVisitor.visit();
// local0 = temp
// local1 = module factory argument
// local2 = style manager
// local3 = inherited styles array
InstructionList initMethod = new InstructionList();
initMethod.addInstruction(ABCConstants.OP_returnvoid);
initMethodBodyVisitor.visitInstructionList(initMethod);
initMethodBodyVisitor.visitEnd();
initMethodVisitor.visitEnd();
ITraitVisitor initMethodTraitVisitor =
classGen.getCTraitsVisitor().visitMethodTrait(ABCConstants.TRAIT_Method, new Name("init"), 0, initMethodInfo);
initMethodTraitVisitor.visitStart();
initMethodTraitVisitor.visitEnd();
codegenInfoMethod(classGen,
flexProject.getCompatibilityVersion(),
getMainClassQName(),
getPreloaderClassReference(),
getRuntimeDPIProviderClassReference(),
splashScreenImage,
getRootNode(),
getTargetAttributes(),
flexProject.getLocales(),
frame1Info,
accessibleClassNames,
getFlexInitClassName(),
getStylesClassName(),
targetSettings.getRuntimeSharedLibraries(),
rslInfo,
problems,
isAppFlexInfo);
}
else
{
MethodInfo initMethodInfo = new MethodInfo();
initMethodInfo.setMethodName("FlexInit init method");
initMethodInfo.setParamTypes(new Vector<Name>(Collections.singleton(iModuleFactoryReference.getMName())));
initMethodInfo.setReturnType(new Name(IASLanguageConstants.void_));
IMethodVisitor initMethodVisitor = emitter.visitMethod(initMethodInfo);
initMethodVisitor.visit();
MethodBodyInfo initMethodBodyInfo = new MethodBodyInfo();
initMethodBodyInfo.setMethodInfo(initMethodInfo);
IMethodBodyVisitor initMethodBodyVisitor = initMethodVisitor.visitBody(initMethodBodyInfo);