Skip to content

Commit

Permalink
PullScrollView 点击事件被占用解决办法
Browse files Browse the repository at this point in the history
  • Loading branch information
Dzws committed Nov 9, 2017
1 parent 43c08fe commit aa34189
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,16 @@ protected void onScrollChanged(int l, int t, int oldl, int oldt) {

@Override
public boolean onInterceptTouchEvent(MotionEvent ev) {
return onTouchEvent(ev) || super.onInterceptTouchEvent(ev);
onTouchEvent(ev);
return super.onInterceptTouchEvent(ev);
}


// @Override
// public boolean onInterceptTouchEvent(MotionEvent ev) {
// return onTouchEvent(ev) || super.onInterceptTouchEvent(ev);
// }

@Override
public boolean onTouchEvent(MotionEvent ev) {
if (mContentView != null) {
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,15 @@ PullScrollView
## **使用示例** ##

```java
1
mScrollView = (PullScrollView) findViewById(R.id.scroll_view);
mHeadImg = (ImageView) findViewById(R.id.background_img);
mScrollView.setOnTurnListener(this);
mScrollView.init(mHeadImg);
2
获取头部View进行修改示例:
TextView tvHello = (TextView)mHeadImg.findViewById(R.id.tv_hello);
tvHello.setText("world");
```

##Screenshots
Expand Down

0 comments on commit aa34189

Please sign in to comment.