Android App Development
iOS App Development
Flutter App Development
Cross Platform App Development
Hire on-demand project developers and turn your idea into working reality.
Big thanks to Webkul and his team for helping get Opencart 188.8.131.52 release ready!
Updated 14 December 2016
The flexible, easy to use, all in one drawer library for your Android project.
Yes that’s true. But there are still shortage of community which provide resources and relavent information about this Material Drawer Library.
In this blog We are going to implement this library in our project. And later we will see how we can tailor the flow as per our application requirement.
You can download the complete sample application from here.
note: add transitive dependencies by setting transitive = true for the material drawer dependency. This will add all the relevant dependency required by the material drawer library.
Also there are some other dependency that we can add to speed up the implementation:
compile ‘com.mikepenz:google-material-typeface:184.108.40.206@aar’ , compile ‘com.mikepenz:fontawesome-typeface:220.127.116.11@aar’ are the GitHub libraries that maintain Google recommended material based icons. This will boost our development process without worrying about the icon required.
We have used Picasso as a image loading and caching library.
Note: Image loading is done in picasso but it can be change to any library.
Note: IProfile is the interface that can be used to display multiple type of profiles based on the requirement.
Here we have passed the ProfileDrawerItem object which is used to display the profile as a drawer item of the Drawer.
We can set the icon from URL ,Drawable , DrawableRes or Bitmap.
Here Identifier is used to identifying a particular element. This is usually used OnDrawerItemClickListener to identify which drawer item has been clicked.
Note: AccountHeaderBuilder class allow up to create a header of the drawer. We can create our custom header or use among the available header files.
You can change the header by using withAccountHeader(R.layout.myHeaderView). Also to set compact header layout use withCompactStyle(true).
Here withOnAccountHeaderListener all the profile changed events related to AccountHeader are managed.
Note: Here we have added multiple type of drawer items namely PrimaryDrawerItem, SectionDrawerItem, ExpandableDrawerItem and like that. Check the main drawer for all types of Drawer items provideded by the Material Drawer library
Here withOnDrawerItemClickListener handles all the drawer items click events related to Drawer.
Also, .withAccountHeader(headerResult) automatically sets the AccountHeader that we created earlier for the header.
That’s all folks. Stay updated.
Your email address will not be published. Required fields are marked*
Save my name email and website in this browser for the next time I comment.
Collapsing toolbar with crossfade, searchbar and a extended actionbutton, plus the latest slider with pinch zoom which I implemented early at dawn before I finally went to sleep. 🙂
I needed to overcome the limitations of a fairly recent obsession: the webview, that I was forced to approach material design beginning with this drawer.
I’m only two weeks in Android development, but I know java for quit a long time and I haven’t tried it for years. I quit java when I realized that there was yet little support for distribution of java enabled phones around 2007 at least in my country, just about the time when Android was yet a company (which I haven’t heard yet back then) and the expense to do it was too high.
Enquiry or Requirement
If you have more details or questions, you can reply to the received confirmation email.