this.sprite = cc.Sprite.create(res.HelloWorld_png);
this.sprite.x=this.sprite.width/2;
this.sprite.y=this.sprite.height/2;
var shopscrollview = ccui.ScrollView.create();
shopscrollview.setDirection(ccui.ScrollView.DIR_BOTH);
shopscrollview.setTouchEnabled(true);
shopscrollview.setSize(cc.size(this.sprite.width, this.sprite.height));
shopscrollview.setBounceEnabled(true);
var scrollViewRect = shopscrollview.getSize();
shopscrollview.x = 0;
shopscrollview.y = 0;
shopscrollview.setInnerContainerSize(cc.size(scrollViewRect.width, scrollViewRect.height));
shopscrollview.addChild(this.sprite);
this.addChild(shopscrollview);
cc.eventManager.addListener({
event: cc.EventListener.TOUCH_ALL_AT_ONCE,
swallowTouches: true,
onTouchesBegan: function (touches, event) {
},
onTouchesMoved: function (touches, event) {
var len = touches.length;
cc.log(len);
},
onTouchesEnded: function (touches, event) {
}
}, shopscrollview);
```
在scrollview外有触摸到的,里面就没了
单点会吞噬了多点触摸,这个要怎么处理呀
楼主实现功能了没?