Lucas
Lucas

Reputation: 69

How to create a floating view over another view in android

I don't know exaclty how it is called, but I got a screenshot: Screenshot

Basically, in this case, I press a button and this window from "FC Barcelona" pops up, occupying about 3/4 of the screen. After it is opened I can drag it up and down. If I drag it up, it occupies the whole screen, if I drag it down, it disappear.

How can I use this tool or how it is called in android?

Upvotes: 2

Views: 1685

Answers (1)

Gauthier
Gauthier

Reputation: 4978

What you want is a BottomSheet. You can find an example on how to do it there at the Design Support Library: Bottom Sheets section.

http://android-developers.blogspot.de/2016/02/android-support-library-232.html

Upvotes: 3

Related Questions