androidfragmentcab

Change the color of Contextual Action Bar


I'm trying to figure out how to change the color of the contextual action bar menu (CAB) for example i want to have red CAB in my app,and i use the CAB in one of my fragments, Any help would be appreciated! Thanks!


Solution

  • You need to add following in your theme defined under styles.xml,​

    <item name="android:actionBarStyle">@style/Widget.Styled.ActionBar</item>
    <item name="android:actionModeBackground">@drawable/actionmode_background</item>`