From 6cf18dc54114b5c78d0f6cad9219e05852996c2e Mon Sep 17 00:00:00 2001 From: Gustavo Martin Morcuende Date: Thu, 1 Sep 2016 20:30:27 +0200 Subject: [PATCH] Split ActionBar does not work with Theme.AppCompat https://commonsware.com/blog/2014/11/18/android-5p0-deprecation-splitactionbarwhennarrow.html http://stackoverflow.com/a/27047159 --- app/src/main/AndroidManifest.xml | 8 +++++++- .../gumartinm/weather/information/activity/MainTabsActivity.java | 2 ++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 31c5221..2e5e7f4 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -66,8 +66,14 @@ + diff --git a/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java b/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java index 5aba1d6..ed99be4 100644 --- a/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java +++ b/app/src/main/java/name/gumartinm/weather/information/activity/MainTabsActivity.java @@ -60,6 +60,8 @@ public class MainTabsActivity extends AppCompatActivity { final ActionBar actionBar = this.getSupportActionBar(); actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE); + actionBar.setDisplayUseLogoEnabled(true); + actionBar.setDisplayShowTitleEnabled(true); actionBar.setDisplayHomeAsUpEnabled(true); actionBar.setDisplayShowHomeEnabled(true); actionBar.setIcon(R.drawable.ic_launcher); -- 2.1.4