Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我已经在我的应用程序中实现了RemoteInput,但是文本字段区域显示为灰色背景 abd 我希望它是蓝色的,如下所示:
有没有办法做到这一点?
UPD:看起来colorPrimary用于此,但我不想在整个应用程序中更改它,只是在通知中
colorPrimary
方法setColor是我一直在寻找的。它还会更改图标和标题色调。
setColor
NotificationCompat.Builder(ctx) //.... .setColor(ContextCompat.getColor(ctx, R.color.colorAccent))