gpt4 book ai didi

flex4 - 在 4.0 中编译时出现奇怪的 "INavigatorContent"错误

转载 作者:行者123 更新时间:2023-12-04 06:52:45 24 4
gpt4 key购买 nike

我最近决定尝试升级到 4.0。我仍然无法解决的唯一错误是这个:

“Halo 导航器的 child 必须实现 INavigatorContent”

我似乎在所有具有验证器的 ViewStack 上都得到了它。

<mx:ViewStack xmlns:mx="http://www.adobe.com/2006/mxml">
<mx:NumberValidator id="systolicValidator"
source="{systolic}"
required="true"
property="text"
minValue="10"
maxValue="300"
domain="int"/>
<mx:NumberValidator id="diastolicValidator"
source="{diastolic}"
required="true"
property="text"
minValue="10"
maxValue="200"
domain="int"/>
<mx:TextInput id="systolic"/>
<mx:TextInput id="diastolic"/>
...
</ViewStack>

错误被抛出到验证器标签上。我的编译器设置为“flex 3 兼容模式”,我的主题设置为 Halo(默认)。

这似乎应该是一个非常直接的修复,所以我讨厌在它上面旋转太久。

任何想法我可能会错过什么?

最佳答案

在阅读了 Flex 4 之后,似乎所有非可视元素都应该放在这些标签中:

<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
</fx:Declarations>

(xmlns:fx="http://ns.adobe.com/mxml/2009")

这个错误有点奇怪。但是,经过一些清理后,我得到了一个更好的错误:

'*' declaration must be contained within the <Declarations> tag since it does not implement 'mx.core.IUIComponent'.



很多,更有帮助。如果我找到之前遇到的奇怪错误的原因,我会再次发布。

关于flex4 - 在 4.0 中编译时出现奇怪的 "INavigatorContent"错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2885897/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com