'Call requires API level 23' error, but getForeground() exists on FrameLayout from API 1
Finally I found the related issue, setForeground()
incorrectly flagged as requiring API 23 for ViewGroups extending FrameLayout
.
If you are not extending FrameLayout
, the documentation is wrong and API 23 is really required.