androidx.legacy
was released in 2018-09-21, and is deprecated now.
Use the latest AndroidX libraries compatible with your targetSdkVersion
and minSdkVersion
. The current stable version of androidx.core
is 1.16.0 and that of androidx.appcompat
is 1.7.1.
WindowInsetsCompat.getInsets()
and WindowInsetsCompat.Type
were added in 1.5.0 (2021-05-18), so you must use androidx.core:core:1.5.0
or later.