List Flex移动列表:如何消除渲染器点击时的灰色覆盖?

List Flex移动列表:如何消除渲染器点击时的灰色覆盖?,list,itemrenderer,flex-mobile,List,Itemrenderer,Flex Mobile,我尝试将所有可能的样式设置为灰色以外的其他样式,只是为了尝试摆脱灰色覆盖,如列表附加图像中的“Hello item 1”所示。什么都没用。我也检查了ListSkin类,没有发现任何会画这些的东西。如何去除这些覆盖物 <s:List id="list" width="100%" height="100%" dataProvider="{dp}" focusAlpha="0" contentBackgroundAlpha=

我尝试将所有可能的样式设置为灰色以外的其他样式,只是为了尝试摆脱灰色覆盖,如列表附加图像中的“Hello item 1”所示。什么都没用。我也检查了ListSkin类,没有发现任何会画这些的东西。如何去除这些覆盖物

<s:List id="list" width="100%" height="100%"
            dataProvider="{dp}"
            focusAlpha="0"
            contentBackgroundAlpha="0"
            contentBackgroundColor="0xFFFFFF"
            selectionColor="0xFFFFFF"
            downColor="0xFFFFFF"
            borderVisible="false"
            >
</s:List>


我刚刚帮了一位客户做了同样的事情。基本上,您必须扩展LabelItemRemder类以不绘制矩形。它不会通过样式或颜色显示,供您更改

查看此代码(从LabelItemRemder中的第853行开始):

您基本上需要某种方法来强制此代码不运行。您可以通过从头创建自己的itemRenderer来实现这一点。或者,您可以扩展LabelItemRenderer,重写DruckGround()方法,并将所有父级DruckGround()代码复制到扩展的子级中;减去上面的方块

我很想看到这种颜色作为一种风格或其他什么暴露出来。我很想看到一个神奇的属性(或风格),我们可以用它来让叠加完全消失。请随意将此作为bug登录到

// Selected and down states have a gradient overlay as well
// as different separators colors/alphas
if (selected || down)
{
    var colors:Array = [0x000000, 0x000000 ];
    var alphas:Array = [.2, .1];
    var ratios:Array = [0, 255];
    var matrix:Matrix = new Matrix();

    // gradient overlay
    matrix.createGradientBox(unscaledWidth, unscaledHeight, Math.PI / 2, 0, 0 );
    graphics.beginGradientFill(GradientType.LINEAR, colors, alphas, ratios, matrix);
    graphics.drawRect(0, 0, unscaledWidth, unscaledHeight);
    graphics.endFill();
}