Android Question bottom nav bar covering content

abhishek007p

Active Member
Licensed User
Longtime User
i have a simple app (using non B4XPages) which displays content in webview and on bottom of app banner ads is displayed. but now i noticed the ads is appearing behind the navigationbar. adding "* 2" seems to fix it. wants to know if this approach is correct.
no problem with app title as im using CreateResourceFromFile(Macro, Themes.LightTheme). target SDK is 36

banner ads code:
Activity.AddView(BannerAd, 0dip, 100%y - (AdaptiveSize.Get("height") * 2),  AdaptiveSize.Get("width"), AdaptiveSize.Get("height"))
 

Attachments

  • Screenshot_20260912_234937.jpg
    Screenshot_20260912_234937.jpg
    57.3 KB · Views: 69
Last edited:

Brian Dean

Well-Known Member
Licensed User
Longtime User
You say that your app does not use B4XPages and that you have moved to SDK 36. That should mean that you have modified your layout to adapt for edge-to-edge enforcement as described here. If you have not made those changes then I expect that explains the effect that you describe. I don't use banner ads myself so I cannot be certain.
 
Upvote 0
Top