简体   繁体   English

检测scrollview是否到达底部钛

[英]detect if scrollview has reached the bottom titanium

I need to detect if the scrollview has reached the bottom when the user scrolls down so i can load more data in tho it? 当用户向下滚动时,我需要检测滚动视图是否已到达底部,以便可以在其中加载更多数据? How can i do this the best way? 我怎样才能做到最好呢? i have tried: 我努力了:

scrollView.addEventListener("scrollend", function(e){
    b = 10;
    AddList();
});

But i't does not solve my problem because it loads data into the scroll when the scrollview stops scrolling and only works in IOS and i need it to work also in android. 但是我没有解决我的问题,因为当scrollview停止滚动并且仅在IOS中工作时,它将数据加载到滚动中,并且我需要它也在android中工作。

I'm not using the alloy folder 我没有使用Alloy文件夹

You are looking for the infinite scroll (facebook timeline, instagram feed, etc;) Without a doubt this module works best for iOS & Android, plus the documentation is clear. 您正在寻找无限滚动(facebook时间轴,instagram提要等;)毫无疑问,此模块最适用于iOS和Android,此外文档非常清晰。 Works with Alloy & Classic Titanium: https://github.com/FokkeZB/nl.fokkezb.infiniteScroll 适用于Alloy&Classic Titanium: https//github.com/FokkeZB/nl.fokkezb.infiniteScroll

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM