Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android L activity header image with transparent toolbar and collapse on-scroll

I have a new KitKat App and I'm trying to reproduce in my activity the layout that you can find in the new Play Store App Activity or Google+ Profile Activity. What I am trying to achieve is to have a transparent toolbar and an "activity-header" image that will collapse on scroll: This is an example

Is there any new appcompat widget or a pattern to follow in order to achieve this result?

like image 528
Otacon Avatar asked Oct 28 '14 09:10

Otacon


2 Answers

You can probably find https://github.com/ManuelPeinado/FadingActionBar useful. Also consult https://plus.google.com/106514622630861903655/posts/Y5iBqpzP4T9 to use the newish Toolbar.

like image 182
sandkeks Avatar answered Sep 23 '22 03:09

sandkeks


You would want to use CollapsingToolbarLayout.

Android Design Support Library has everything you need.

like image 35
Ken Tan Avatar answered Sep 23 '22 03:09

Ken Tan