有任何方法可以在RecyclerView中设置和更新RemoteView吗?我想在通知中显示一个RecyclerView。我已经在通知中设置了自定义视图,但无法在RecyclerView中设置数据,请参见以下内容:
// my playout passed here have a Recycler View
// How to findViewById there and set my data?
val contentView = RemoteViews(packageName, R.layout.notification_layout)
val mBuilder = NotificationCompat.Builder(this)
.setSmallIcon(R.mipmap.ic_launcher)
.setContent(contentView)发布于 2018-05-20 13:38:26
,不,你不能。通知有固定的最大大小,即使您可以发送自定义的RemoteView,也没有使用ListView或RecyclerView并使用Adapter填充它们的选项。
https://stackoverflow.com/questions/50434161
复制相似问题