I'm using the Theme.AppCompat.Light.DialogWhenLarge in my activity, and I set up an adView via xml with adSize="SMART_BANNER". In small screens, the behavior of the smart banner works fine as expected, but when in large screens the activity switches to the dialog theme, the adview still calculates its width on the
screen width, not the activity window's width, resulting in the banner not being shown because the space available is less than the size requested, as proved by logcat messages.
Actually I worked this out by putting a copy of the activity's layout in layout/large and switching to adSize="FULL_BANNER" in this layout: the banner has fixed width and fills in the dialog.
Yet, I'm wondering if smart banner's behavior can't be modified so that it requests its size based on activity's width, instead of screen width. I tried with AdView.setAdSize() but this throws an excpetion saying that the size can be set only once.