Apache flex Flex 3.x中的$height是多少?

Apache flex Flex 3.x中的$height是多少?,apache-flex,actionscript-3,flexbuilder,Apache Flex,Actionscript 3,Flexbuilder,在Flex(3.5版)中调试一些容器大小(即HBox)时,我注意到变量列表中有一个变量“$height” 有人知道这个变量是什么吗?它被标记为受保护,但我不相信我可以在子类中访问它 我注意到它有时会得到一个不同于“height”和“_height”的值。有人知道这是为什么,以及它对如何绘制组件意味着什么吗?Flex覆盖了它的自定义对象中的许多方法,例如FlexSprite 在它们的内部代码库中,它们经常声明新方法,并将其标记为“final”和super(),作为默认方法实现。最后的这些方法以“$

在Flex(3.5版)中调试一些容器大小(即HBox)时,我注意到变量列表中有一个变量“$height”

有人知道这个变量是什么吗?它被标记为受保护,但我不相信我可以在子类中访问它


我注意到它有时会得到一个不同于“height”和“_height”的值。有人知道这是为什么,以及它对如何绘制组件意味着什么吗?

Flex覆盖了它的自定义对象中的许多方法,例如FlexSprite

在它们的内部代码库中,它们经常声明新方法,并将其标记为“final”和super(),作为默认方法实现。最后的这些方法以“$”开头,因此易于识别


您将看到的另一个示例是“$addChild”,flex具有自定义的addChild功能,但通过“$addChild”方法在内部使用原始实现。

完整的mx framework源代码可在sdk目录中找到:

\..\sdks\3.3.0\frameworks\projects\framework\src
私人文件说

 /*
 *  This property allows access to the Player's native implementation
 *  of the 'height' property, which can be useful since components
 *  can override 'height' and thereby hide the native implementation.
 *  Note that this "base property" is final and cannot be overridden,
 *  so you can count on it to reflect what is happening at the player level.
 */

它用
mx_internal
标记,因此您需要声明
使用名称空间mx_internal
在您自己的课堂上访问它。

您知道,我从来没有想过要查看源代码:)谢谢!