Comments (1)
可以通过重写 SwipeRefreshLayout 的 onInterceptTouchEvent() 方法来实现支持。
参考如下代码:
@Override
public boolean onInterceptTouchEvent(MotionEvent ev) {
boolean isIntercept = true;
switch (ev.getAction()) {
case MotionEvent.ACTION_DOWN:
mDownY = (int) ev.getY();
break;
case MotionEvent.ACTION_HOVER_MOVE:
int dy = (int) (mDownY - ev.getY());
if (dy > 0) isIntercept = false;
}
return mWebView.getScrollY() == 0 &&
mScrollView.getScrollY() == 0 &&
isIntercept &&
super.onInterceptTouchEvent(ev);
}
from android-nesteddetail.
Related Issues (18)
- 使用一下GitHub图床功能
- webview滑动和SwipeBackActivity侧滑返回冲突,侧滑失效 HOT 1
- 滑动到底部再向上滑动时有bug HOT 3
- WebView的高度wrap_content的时候,页面高度不对,会造成一系列的bug HOT 2
- 不支持动态web页面
- 怎么判断滑动到了底部
- 头部放不滑动的view有问题的
- H5无法监听到WebView的onScroll回调。
- 不支持x5webview
- WebView前面添加的组件不跟随滑动 HOT 1
- 底部改成输入框就会有问题哦 HOT 2
- 有个问题想请教一下 HOT 1
- 可以有下拉刷新功能吗 HOT 1
- 增加推荐阅读等 HOT 2
- 固定不动的view只能加在webview和Recyclerview之间?在webview头部再加一个跟随滑动的view需要怎么操作呢? HOT 1
- computeScroll中的事件传递问题 HOT 4
- 把webview换成RecyclerView 展示不全
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from android-nesteddetail.