有没有办法在触摸设备上收听famous-angular的fa-scroll-view滚动事件?
例如,在着名的角度文档之外:
<fa-app ng-controller="ScrollCtrl">
<!-- fa-scroll-view receives all events from $scope.myEventHandler, and decides how to handle them -->
<fa-scroll-view fa-pipe-from="myEventHandler">
<fa-view ng-repeat="view in views">
<fa-modifier fa-size="[undefined, 160]">
<!-- All events on fa-surfaces (click, mousewheel) are piped to $scope.myEventHandler -->
<fa-surface fa-background-color="view.color"
fa-pipe-to="myEventHandler">
</fa-surface>
</fa-modifier>
</fa-view>
</fa-scroll-view>
</fa-app>
我可以使用
收听myEventHandler
上的点击次数
$scope.myEventHandler.on('click', ...)
但不是滚动:
$scope.myEventHandler.on('scroll', ...) // doesn't fire
这可能吗?
感谢。
答案 0 :(得分:2)
$ famous.find('fa-scroll-view')[0] .renderNode.sync.on('start',function(event){console.log('start');}); 还有'更新'和'结束'事件