
val p1 = Pair.create(imageVIEwhospitals,"hospitals") val p2 = Pair.create(textVIEwhospitals,"Title") val options = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LolliPOP) { ActivityOptions.makeSceneTransitionAnimation(this,p1,p2) } else { Todo("VERSION.SDK_INT < LolliPOP") }startActivity(Intent(this,SplashActivity::class.java),options.toBundle()) 我收到错误/警告
none of the following function can be called with the arguments
supplIEd
在ActivityOptions.makeSceneTransitionAnimation上
解决方法 最后我通过改变来解决这个问题val p1 = Pair.create(imageVIEwhospitals,"hospitals")val p2 = Pair.create(textVIEwhospitals,"Title")
至
val p1 = Pair.create<VIEw,String>(imageVIEwhospitals,"hospitals")val p2 = Pair.create<VIEw,String>(textVIEwhospitals,"Title")总结
以上是内存溢出为你收集整理的android – ActivityOptions.makeSceneTransitionAnimation无法在kotlin中使用多个视图全部内容,希望文章能够帮你解决android – ActivityOptions.makeSceneTransitionAnimation无法在kotlin中使用多个视图所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)