Last active
August 29, 2015 14:02
-
-
Save martyglaubitz/c2636ca6689b992ae058 to your computer and use it in GitHub Desktop.
Fix: Android Actionbar Tabs appear over ActionBar
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
final View homeIcon = findViewById(android.R.id.home); | |
((View) homeIcon.getParent()).setVisibility(View.GONE); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<style name="AppTheme.ActionBar" parent="@style/Widget.AppCompat.ActionBar"> | |
<!-- visually "hide" the icon itself--> | |
<item name="android:icon">@android:color/transparent</item> | |
<item name="icon">@android:color/transparent</item> | |
<!-- these are required to prevent the tabs getting over the actionbar when adding a customview to it --> | |
<item name="android:displayOptions">showCustom|showHome</item> | |
<item name="displayOptions">showCustom|showHome</item> | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment