gpt4 book ai didi

Android ConstraintLayout 向后兼容旧的 android 版本?

转载 作者:行者123 更新时间:2023-11-29 18:25:55 25 4
gpt4 key购买 nike

我正在使用 Android Studio 3.5 并开发必须在 Android 4.0 及更高版本上运行的新 Android 应用程序。

我想使用 ConstraintLayout。我的应用程序是否与 Android 4.0 兼容?

最佳答案

minsdk 取决于所使用的库:

有了支持库(类是android.support.constraint.ConstraintLayout)你可以使用:

implementation 'com.android.support.constraint:constraint-layout:1.1.3' --> minSdk=9

使用androidx(类是androidx.constraintlayout.widget.ConstraintLayout)你可以使用:

implementation "androidx.constraintlayout:constraintlayout:2.0.0-beta2" --> minSdk=14
implementation "androidx.constraintlayout:constraintlayout:1.1.3" --> minSdk=9

关于Android ConstraintLayout 向后兼容旧的 android 版本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59045648/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com