首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Flex SkinPart被定义为必需的false。编译器会生成错误。

Flex SkinPart被定义为必需的false。编译器会生成错误。
EN

Stack Overflow用户
提问于 2012-06-11 08:26:32
回答 1查看 1.1K关注 0票数 1

我有一个s:SkinnableContainer基类,它将几个皮肤部件定义为[SkinPart(required="false")]。这个类是由几个具有定义(如[SkinPart(required="true")] )的不同类划分的。每个子类都有自己的皮肤,实现所有required=true皮肤部分。其中一些实现了required=false皮肤部分。

flex编译器随机生成以下错误:

代码语言:javascript
复制
The required skin part '__moduleFactoryInitialized' is missing. ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part '_selectedApplication' is missing.   ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part '_skinClass' is missing. ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part 'initialize' is missing. ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part 'initialize' is missing. ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part 'ux_title' is missing.   ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The required skin part 'ux_titleSignpost' is missing.   ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The skin part type 'components:BooleanButtonBar' must be assignable to 'spark.components:Button'.   ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The skin part type 'components.renderers:StateRenderer' must be assignable to 'spark.components:NumericStepper'.    ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The skin part type 'spark.components:NumericStepper' must be assignable to 'components.renderers:StateRenderer'.    ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The skin part type 'spark.components:NumericStepper' must be assignable to 'spark.components:Label'.    ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem
The skin part type 'spark.components:VGroup' must be assignable to 'spark.components.supportClasses:TextBase'.  ThresholdPercentageWidgetSkin.mxml  /am-apm-app-ui/src/main/flex/styles/skins   line 12 Flex Problem

例如,required skin part 'ux_title' is missing错误涉及标签,即required=false

此外,提到的一些皮肤部分是内部的。例如- __moduleFactoryInitialized_skinClassinitialize

现在,在其中一个文件中添加新行,将生成一个成功的编译。

我试着从看不见的特殊字符中清理文件。

知道为什么会发生吗?

我试过你建议工作-不起作用。但我的错误有点不同

代码语言:javascript
复制
[ERROR] <filename>[13,-1] The skin part type 'spark.components:Label' must b
 e assignable to 'spark.components:Button'.
[ERROR] <filename>:[13,-1] The skin part type 'components.help:SignPost' must
 be assignable to 'spark.components:Button'.

还有以上两个例子。注意13,-1行/列对。-1表示内部出了问题。

谢谢。

EN

回答 1

Stack Overflow用户

发布于 2012-06-25 14:48:18

我只是碰到了同样的问题。它只发生在我们的CI服务器上。我在工作站上尝试了所有可用的4.6编译器,但无法用相同的代码再现问题。作为一项工作,我改变了

代码语言:javascript
复制
[SkinPart(required="true")]

代码语言:javascript
复制
[SkinPart]

就目前而言。我试着保留生成的Actionscript来尝试定位问题,但是我没有看到会导致问题的任何东西。我之所以尝试这样做,是因为编译器错误最初是关于我自己代码中的变量需要SkinParts (但实际上根本不是皮肤部分)。基于文章中的一个注释,我扫描了代码中的任何非ascii字符,但是没有。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/10976641

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档