Android Question Unexpected behavior of Title Bar

Hello, is there a simple way to make the Application have the same behavior on older versions of Android?
  • In version 4.1.2 the app icon appears, but not the menu
  • In versions 6.0, 7.0 it happens the other way around: the menu appears but not the icon
Android 4.1.2



Android_4.1.2.jpg
Android 6.0; 7.0

Android_7.0.png


I would like both to appear in all versions
Thanks in advance
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
I recommend you to ignore Android 4 devices. They are very rare now.

The image on the top left corner is usually used for an 'up' or 'drawer' buttons.
This code, from B4XPages + B4XDrawer example shows a hamburger icon:
B4X:
B4XPages.GetManager.ActionBar.RunMethod("setDisplayHomeAsUpEnabled", Array(True))
Dim bd As BitmapDrawable
bd.Initialize(HamburgerIcon)
B4XPages.GetManager.ActionBar.RunMethod("setHomeAsUpIndicator", Array(bd))
 
Upvote 0
Top