1

Usually the Drawer Layout is hidden on the view until the onTouch or onSwipe in is triggered. I'd like to make the drawer layout initially displayed. I also checked out the SlidingLayer Library but It is more complicated that the new drawer layout that Android has released. In the image below, the blue lines represents the initial drawer that needs interaction which also triggers the opening and closing of the drawer.

My last resort on this it to have a button, on the view that will handle the interaction, but as much as possible I want to have a normal view on drawer layout.

I have seen this on the documentation, not sure what it does:

setDrawerShadow(Drawable shadowDrawable, int gravity)
Set a simple drawable used for the left or right shadow.

enter image description here

rahstame
  • 2,148
  • 4
  • 23
  • 53
  • the `setDrawerShadow(Drawable shadowDrawable, int gravity)` method, it just sets a drawable to the right of your drawer, as you would do when using `android:background="@drawable/dropshadow"` on a layout – Guillaume Aug 13 '13 at 12:14
  • as for your question, could you clarify if the blue drawer is the entire drawer or only a part of it, like 100px of the right side? or it's a completely different view? because if you want it open, you can simply call `drawer.openDrawer(...)` when view is created – Guillaume Aug 13 '13 at 12:15
  • Thanks for explaining the `setDrawerShadow`. the blue drawer is just a drawable that represent the `drawer` also handles the opening and closing of the drawer, which has a sliding effect during the interaction. – rahstame Aug 14 '13 at 01:47
  • so pretty much the same thing as http://stackoverflow.com/questions/17884277/how-to-implement-a-drawerlayout-with-a-visible-handle – Guillaume Aug 14 '13 at 12:23

0 Answers0