Elevation Effect for ImageButton on Pre-Lollipop Devices

I am trying to apply the elevation effect for ImageButton. It works well on my Nexus tablet running Android 5.0, but the height doesn't work on Pre-Lollipop devices.

Tried ViewCompat.setElevation (view, evaluationValue), but nothing has changed.

I saw that some applications, such as Swarm or Gmail applications, use the enhancement effect for their FAB (floating action button) on Pre-Lollipop devices.

Do you have an idea how they use height?

+4
source share
3 answers

5.0, "",

+6

as indicated in this post , set the background

Android: background = "@ android: draw / dialog _holo_light_frame"

it looks like a raised button on the front candy.

0
source

All Articles