Kotlin Android扩展-支持片段中没有合成属性

Kotlin Android扩展-支持片段中没有合成属性,android,android-fragments,kotlin,kotlin-android-extensions,androidx,Android,Android Fragments,Kotlin,Kotlin Android Extensions,Androidx,我有一个Android项目,有这样的依赖关系 implementation 'com.android.support:appcompat-v7:28.0.0' implementation 'com.android.support:design:28.0.0' implementation 'com.android.support:recyclerview-v7:28.0.0' implementation 'com.android.support.constraint:constraint-l

我有一个Android项目,有这样的依赖关系

implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:design:28.0.0'
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
该项目是用Kotlin编写的,使用了视图元素的合成属性。我的项目中的片段实现扩展了包android.support.v4.app中的片段。我遇到了一个问题,在我的片段中,我无法通过合成访问我的视图-我得到的信息如下:

未解析的引用。下列候选人均不适用 因为 接收者类型的不匹配:public val Activity.detailButton:Button!定义 在kotlinx.android.synthetic.main.fragment\u中欢迎公共val Dialog.detailButton:按钮!定义于 kotlinx.android.synthetic.main.fragment_欢迎公共val android.app.fragment.detailButton:按钮!定义于 kotlinx.android.synthetic.main.fragment_欢迎公共val androidx.fragment.app.fragment.detailButton:按钮!定义于 kotlinx.android.synthetic.main.fragment_欢迎公共val LayoutContainer.detailButton:按钮!定义于 kotlinx.android.synthetic.main.fragment_欢迎

解决这个问题的唯一方法是从androidx.fragment扩展fragment,但我只需要来自支持库的片段!在项目的其他部分(例如带有LayoutContainer的ViewHolder),合成特性功能可以正常工作。所以我需要一个帮助来解决这个问题

最近,在Android Studio中,我使用“重构迁移到AndroidX”功能迁移到AndroidX。但它是在备份项目上制作的。也许这会影响我的处境