Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/apache-flex/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Apache flex 使用ItemRenderer的Tilelist中的拖放问题_Apache Flex_Flash_Actionscript 3_Drag And Drop_Tilelist - Fatal编程技术网

Apache flex 使用ItemRenderer的Tilelist中的拖放问题

Apache flex 使用ItemRenderer的Tilelist中的拖放问题,apache-flex,flash,actionscript-3,drag-and-drop,tilelist,Apache Flex,Flash,Actionscript 3,Drag And Drop,Tilelist,在我的flex应用程序中,我创建了一个Tilelist。在这个平铺列表中,我使用ItemRenderer创建一个框,每个平铺中包含一个图像和一个VSlider 单击图像时,平铺需要可拖动,但滑动滑块时,平铺不需要可拖动。我怎样才能做到这一点?我在谷歌上搜索了一天,真的不知道该怎么办 我期待你的帮助。 谢谢。我找到了解决我问题的办法,但可能不是最好的办法 使用此选项: public var overImage:Boolean = false; public fun

在我的flex应用程序中,我创建了一个Tilelist。在这个平铺列表中,我使用ItemRenderer创建一个框,每个平铺中包含一个图像和一个VSlider

单击图像时,平铺需要可拖动,但滑动滑块时,平铺不需要可拖动。我怎样才能做到这一点?我在谷歌上搜索了一天,真的不知道该怎么办

我期待你的帮助。
谢谢。

我找到了解决我问题的办法,但可能不是最好的办法

使用此选项:

        public var overImage:Boolean = false;

        public function checkAllow(evt:DragEvent):void {

            if(overImage == false)
            {
                evt.preventDefault()
            }
        }

        public function isOverImage():void {
            overImage = true;
        }

        public function isOutImage():void {
            overImage = false;
        }
我将这些函数称为:

关于我的图像组件

mouseOver="outerDocument.isOverImage()" mouseOut="outerDocument.isOutImage()"
为了我的提琴手,我做了这件事

Tiles.addEventListener(DragEvent.DRAG_START, checkAllow);
希望它能帮助一些人

            if(event.target is ScrollThumb )
        {
            return;
        }
通过在imageDragStart方法中返回sroller的scrollThumb属性解决了此问题

背景:My TileList随mouseDown=“event.currentTarget.addEventListener(MouseEvent.MOUSE_MOVE,imageDragStart)”一起提供

这是一个完整的卷轴列表

以上是临时解决方案,但期待专家的建议

基本上,这是用于本机应用程序(AIR),用于NativeDragStart。但我不得不在TileList上使用mouseDown来调用我的imageStartDrag()方法