📜 ⬆️ ⬇️

ActionBar on Android 2.1 using the Android Support Library

Recently on the site developer.android.com I found a new version of SupportLibrary - android.support.v7 . Among other things, it adds support for ActionBar for Android 2.1 and higher.

Projects such as ActionBarSherlock and HoloEwerywhere have a serious competitor. This library contains such useful classes as ActionBar and everything for working with it. Action Mode is also present. Most likely, all methods remained from ActionBar for API 11 and above. The full list of changes is here .

By the way, to use all this, you need to inherit your Activity from ActionBarActivity , and the Basic theme of the application - from Theme.AppCompat , which is contained in the same library. You can not worry about the support of fragments, because it is inherited from FragmentActivity. BUT, to make it all available in your projects, you need to update the Android Support Library via the SDK Manager. By the way, there is already an SDK for Android 4.3, so hurry to download!

')

Source: https://habr.com/ru/post/187976/


All Articles