我目前正在开发一个应用程序,它使用旧版本的android支持库(当前版本是27.0.1,我的项目有23.1.1和23.0.1的组合。
我多年来尝试将版本更新到最新版本(实际上是当前版本以上),以及调整所有支持库版本,但是当我这样做时,我的Recycler Views开始行为不端(奇怪的间距,崩溃等...),截图比较:
在:
后:
我完全不知道如何解决它,任何帮助将不胜感激!
导致错误的新gradle依赖项(之后):
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:27.0.1'
compile 'com.android.support:support-v13:27.0.1'
compile 'com.android.support:cardview-v7:27.0.1'
compile 'com.android.support:recyclerview-v7:27.0.1'
compile 'com.android.support:design:27.0.1'
compile 'com.android.support:percent:27.0.1'
compile 'com.android.support:customtabs:27.0.1'
compile 'com.github.medyo:fancybuttons:1.5@aar'
compile 'com.sothree.slidinguppanel:library:3.2.1'
compile 'com.squareup.okhttp3:okhttp:3.1.2'
compile 'com.balysv.materialmenu:material-menu:2.0.0'
compile 'com.github.d-max:spots-dialog:0.7@aar'
compile 'com.google.code.gson:gson:2.8.0'
compile 'org.apache.commons:commons-lang3:3.0'
compile 'io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:1.0.4'
compile 'com.github.kenglxn.QRGen:android:2.2.0'
compile 'com.github.kenglxn.QRGen:core:2.2.0'
compile 'com.makeramen:roundedimageview:2.3.0'
compile 'org.bitbucket.b_c:jose4j:0.5.2'
compile 'com.wang.avi:library:2.1.0'
compile(name: 'tealium-5.0.4', ext: 'aar')
compile('com.crashlytics.sdk.android:crashlytics:2.6.5@aar') {
transitive = true;
}
compile 'org.parceler:parceler-api:1.1.9'
annotationProcessor 'org.parceler:parceler:1.1.9'
compile 'com.facebook.android:facebook-android-sdk:4.15.0'
// Required -- JUnit 4 framework
testCompile 'junit:junit:4.12'
// Optional -- Mockito framework
testCompile 'org.mockito:mockito-core:1.10.19'
}
生产(之前)gradle依赖项,有效:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:support-v13:23.1.0'
compile 'com.android.support:cardview-v7:23.0.1'
compile 'com.android.support:recyclerview-v7:23.0.1'
compile 'com.android.support:design:23.1.1'
compile 'com.android.support:percent:23.1.0'
compile 'com.github.medyo:fancybuttons:1.5@aar'
compile 'com.sothree.slidinguppanel:library:3.2.1'
compile 'com.squareup.okhttp3:okhttp:3.1.2'
compile 'com.google.android.gms:play-services-appindexing:9.0.1'
compile 'com.balysv.materialmenu:material-menu:2.0.0'
compile 'com.github.d-max:spots-dialog:0.7@aar'
compile 'com.google.code.gson:gson:2.8.0'
compile 'org.apache.commons:commons-lang3:3.0'
compile 'io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:1.0.4'
compile 'com.github.kenglxn.QRGen:android:2.2.0'
compile 'com.github.kenglxn.QRGen:core:2.2.0'
compile 'com.makeramen:roundedimageview:2.3.0'
compile 'org.bitbucket.b_c:jose4j:0.5.2'
compile 'com.wang.avi:library:2.1.0'
compile(name: 'tealium-5.0.4', ext: 'aar')
compile('com.crashlytics.sdk.android:crashlytics:2.6.5@aar') {
transitive = true;
}
compile 'org.parceler:parceler-api:1.1.9'
annotationProcessor 'org.parceler:parceler:1.1.9'
compile 'com.facebook.android:facebook-android-sdk:4.15.0'
// Required -- JUnit 4 framework
testCompile 'junit:junit:4.12'
// Optional -- Mockito framework
testCompile 'org.mockito:mockito-core:1.10.19'
}