Skip to content

Instantly share code, notes, and snippets.

@mahdimortazavi
Created June 14, 2016 15:25
Show Gist options
  • Save mahdimortazavi/dc6f9d628d3f57e1b065be2c95da67b1 to your computer and use it in GitHub Desktop.
Save mahdimortazavi/dc6f9d628d3f57e1b065be2c95da67b1 to your computer and use it in GitHub Desktop.
app:showAsAction
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto">
<item
android:id="@id/item_menu_1"
android:icon="@drawable/icon_user"
app:showAsAction="ifRoom"
android:title="item 1" />
<item
android:id="@id/item_menu_2"
app:showAsAction="never"
android:title="item 2"/>
</menu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment