Take the 2-minute tour ×

I have been toying with a few different libraries and code snippets for the past few days. I am trying to create a menu like the one seen in the facebook app. Now there are many libraries and resources on building something of that kind, but I'm having major difficulties in drawing a shadow between the 'top' and 'bottom' page as to create the illusion that the 'top' page is actually on top. Now the exact effect Im trying to create is displayed in this article: http://android.cyrilmottier.com/?p=717

The author of the article I got this from is not very thorough in his explanation. This could be due to my programming-skills-under-development, or maybe I'm not the only one. I'm using the following library and example app to test and develop with: https://github.com/jfeinstein10/SlidingMenu

I would be very happy if anyone could help me get this to work.

PS: I'm very sorry, but since I'm a newbie here I am not allowed to post any pictures.

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

What I did is I'm putting a shadow at the right of my menu view (ie behindView) with a margin on the right of your above view :

<!-- Show shadow on the right of the menu -->

With my shadow layout:


                android:angle="0" />

share|improve this answer
This is something I have tried myself. While it does provide the effect I'm looking for AFTER the menu has been pulled and not while it's being pulled. –  Daft Fox Jul 11 '12 at 14:54
true, you can use a translation animation to follow the movement of the above view with the shadow if you know the speed or distance and time –  Camille R Jul 11 '12 at 14:57
I will work on moving the shadow around later. Will keep you updated if I may succeed. –  Daft Fox Jul 23 '12 at 15:10
add comment

Your Answer


