SlidingTabs Android Library
• •
This library project is on GitHub.
With the release of Android Studio 1.0, one of the things to notice is that there’s an option to import an Android code sample. All these samples are available on GitHub/googlesamples.
While having those projects available is good, I think it would be even better to make all these samples available as libraries for everyone to use and contribute in a single codebase. For example, if you look at the code of both the SlidingTabs sample projects, SlidingTabsBasic and SlidingTabsColor, you’ll notice that both of them have the same exact code under a com.example.android.common
package.
I’m working on a basic open-source Imgur client for Android where I needed to include the Sliding Tabs from the samples, so I decided to make the job a little easier for everyone and publish the views from the common
package as a library.
The library is called Sliding Tabs and it consists of the SlidingTabLayout
and SlidingTabStrip
classes, with minor modifications to work from minSDK 8. All contributions are welcome; open a PR or refer to the issues section.
You can see an example of this library in Imgurdroid. And although not using this library, the same code is used in Google I/O Android App and, of course, Android SlidingTabsBasic Sample and Android SlidingTabsColors Sample.
Here are a few screenshots of the library in action: