簡體   English   中英

為什么在彈出窗口中打開時,我的rect填充不同的顏色?

[英]Why is my rect fills a different color when opening in a popup?

我要在面板中添加一個包含Rect填充的組。 該面板包含正常和normalWithControlBar兩個狀態。 該組位於normalWithControlBar中。 在隔離測試中,它可以正常工作。 當它在我的應用程序中顯示時,Rect背景填充不會以正確的顏色顯示。

我認為可能在某個地方設置了blendMode,但我不確定是否是它,或者在哪里以及為什么應用它。

我也有可能是Rotate3D效果的原因。 由於它是一個大型應用程序,因此我正在盡力解決可能出現的問題,但是在此之前,還沒有人聽說過此問題或可能由什么原因引起的嗎? 謝謝

示例代碼:

在面板中:

<MyPanel>
    <s:controlBarContent>
        <local:MyGroup width="500" height="230"/><!--appears tinted-->
    </s:controlBarContent>

    <local:MyGroup width="500" height="230"/><!--appears normal-->
</MyPanel>

在MyGroup中:

<s:Rect width="100%" height="80"
        top="100"
            >
    <s:fill>
        <s:SolidColor color="#dddddd"/>
    </s:fill>
</s:Rect>

找到了。 發生這種情況的原因是,該組未添加到面板的外觀類的排除列表中,並且在Application CSS中指定了chromeColor。

在MyPanelSkin中:

之前:

/* Define the skin elements that should not be colorized. */
static private const exclusions:Array = ["background", "titleDisplay", "contentGroup", "controlBarGroup", "border"];

后:

/* Define the skin elements that should not be colorized. */
static private const exclusions:Array = ["myGroup", "background", "titleDisplay", "contentGroup", "controlBarGroup", "border"];

將皮膚部分添加到排除列表后,填充顏色將正確顯示。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM