SkillAgentSearch skills...

ParallaxHeaderViewPager

ParallaxHeaderViewPager

Install / Use

/learn @ngstyle/ParallaxHeaderViewPager
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

ParallaxHeaderViewPager

RelativeLayout hosting a ViewPager

Use a RelativeLayout as our outer container, which hosts the ViewPager and consists of three scrollable fragments. This outer RelativeLayout also hosts the top image and toolbar.

Each of the ViewPager’s fragments implements a callback that is responsible for keeping track of, and updating its scroll position and the top offset within the parent RelativeLayout. As the user scrolls up and down, or side-swipes to a different tab, the callback in the individual ViewPager fragment intelligently adjusts the contained ScrollView’s or ListView’s internal top offset and scroll position to reveal the correct amount of parallaxed image underneath, achieving the visual effect desired.

Related Skills

View on GitHub
GitHub Stars6
CategoryDevelopment
Updated9y ago
Forks0

Languages

Java

Security Score

55/100

Audited on Oct 21, 2016

No findings