Flex的ID contentGroup的查询 [英] Flex id contentGroup query

查看:150
本文介绍了Flex的ID contentGroup的查询的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

IAM学习Flex和实践的皮肤。所以,我只是有一个疑问:

iam learning Flex and practising skins. So, i just had one doubt:

我已经写了一个名为自定义皮肤: ApplicationContainerSkin.mxml

I have written one custom skin named : ApplicationContainerSkin.mxml

<?xml version="1.0" encoding="utf-8"?>
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009" 
             xmlns:s="library://ns.adobe.com/flex/spark" 
             xmlns:mx="library://ns.adobe.com/flex/mx">

    <s:states>
        <s:State name="normal" />
        <s:State name="disabled" />
    </s:states>


    <fx:Metadata>
        [HostComponent("spark.components.Application")]
    </fx:Metadata>


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

    <s:Group horizontalCenter="0" verticalCenter="0">

        <s:Rect left="0" right="0" top="0" bottom="0"
                radiusX="10" radiusY="10">
            <s:fill>
                <s:SolidColor color="#CCCCCC" />
            </s:fill>
        </s:Rect>


        <s:Group id="contentGroup"
                 left="30" right="30" top="30" bottom="30">

        </s:Group>

    </s:Group>

</s:SparkSkin>

我的疑问: 当我删除 S:组id =contentGroup的,IAM无法看到我的应用程序内的任何内容,所以这是为什么 contentGroup的'身份证必要

My Doubt: When I removed s:Group id="contentGroup" , iam unable to see any content inside my application, so why is this 'contentGroup' id necessary?

在哪里这个ID predefinedly规定?对不起,如果它是一个小白查询,但IAM急于知道它。我甚至试图检查源$ C ​​$ C,但我没有发现它,谁能告诉我它规定?如何我的内容使用该contentGroup的后只渲染ID ...? (我的意思是,它在内部如何运作的?)

where this id predefinedly specified.? sorry if its a noob query, but iam eager to knew it.I even tried to check the source code, but I didnt found it, Could anyone tell me where it specified and how does my content render only after using this contentGroup id...? ( I mean, how it internally works? )

等待你的答复!

推荐答案

换肤Spark组件注明皮肤部件,确定的ID。

Skinnable Spark components specify "skin parts," identified by the id.

应用程序组件,您要剥皮,定义2外观部件 - contentGroup的和controlBarGroup,你可以在这里的文档中看到:<一href="http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/Application.html#SkinPartSummary" rel="nofollow">http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/Application.html#SkinPartSummary

The Application component, which you are skinning, defines 2 skin parts - contentGroup and controlBarGroup, as you can see in the documentation here: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/Application.html#SkinPartSummary

应用程序类使用contentGroup的外观部件(如果它在皮肤中添加)布置的内容。可以要求或没有皮肤的部分。不是必需的contentGroup的一部分,因此当你离开它,内容只是不显示。

The Application class uses the contentGroup skin part (if it has been added in the skin) to lay out the content. Skin parts can either be required or not. The contentGroup part is not required, and therefore when you left it out, the content just did not display.

这篇关于Flex的ID contentGroup的查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆