Skip to content

Commit

Permalink
Merge pull request #12 from ashishg656/master
Browse files Browse the repository at this point in the history
When PEWImageView is used as a item in RecyclerView or ListView with fixed image height
  • Loading branch information
Narfss committed Nov 22, 2016
2 parents e845bb3 + e555a77 commit e724c33
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,8 @@ private void applyParallax() {
setMyScrollY((int) (Math.min(Math.max((0.5f - interpolatedScrollDeltaY), -0.5f), 0.5f) * -scrollSpaceY));
else
setMyScrollY((int) (Math.min(Math.max((0.5f - interpolatedScrollDeltaY), -0.5f), 0.5f) * scrollSpaceY));
}else{
setMyScrollY(0);
}

if (scrollSpaceX != 0 && !blockParallaxX) {
Expand All @@ -271,6 +273,8 @@ private void applyParallax() {
} else {
setMyScrollX((int) (Math.min(Math.max((0.5f - interpolatedScrollDeltaX), -0.5f), 0.5f) * scrollSpaceX));
}
}else{
setMyScrollX(0);
}
}

Expand Down

0 comments on commit e724c33

Please sign in to comment.