Java中的材料过渡不起作用

huangapple go评论77阅读模式
英文:

Material transition in java does not work

问题

Android Studio为什么显示这个错误?我查看了文档和其他问题,这里没有问题,无法在setSharedElementEnterTransition中实现MaterialContainerTransform。以下是错误的截图:问题截图

英文:

android studio show me this error why? i saw documentation and other issues here and they no have problem whit implementing MaterialContainerTransform in setSharedElementEnterTransition...

here are an image of the error: issue transition

答案1

得分: 0

根据Google提供的文档,你需要在Activity中为共享元素进行导入:

import com.google.android.material.transition.platform.MaterialContainerTransform

参考链接:https://material.io/develop/android/theming/motion/

英文:

As document from google stated that you need to import for shared element between Activity

 import com.google.android.material.transition.platform.MaterialContainerTransform

Reference: https://material.io/develop/android/theming/motion/

huangapple
  • 本文由 发表于 2020年10月7日 15:59:18
  • 转载请务必保留本文链接:https://go.coder-hub.com/64239715.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定