android - Kotlin 中未解决的参考“设置”
问题描述
我正在尝试使用putInt在 System Settings 属性中写入一些值,但出现错误。编译器说“未解决的参考设置”。请检查以下代码 -
Settings.System.putInt(context.contentResolver, SETTINGS_1, shutterOpen)
Settings.System.putInt(context.contentResolver, SETTINGS_2, muted)
有人可以帮忙吗?我是否必须导入任何额外的东西才能使用此功能?我是 Kotlin 的新手,由于资源限制,我很难修复它。
解决方案
推荐阅读
- javascript - 当我尝试在组件中使用 antd 的表单时,无法读取未定义的属性“getFieldDecorator”
- javascript - 如何使用 excel.js 库编辑 Multer 发布的文件?
- c++ - 链表插入,指针混淆
- python - 使用 OpenCV 检测文档扫描中的矩形签名字段
- mysql - 如何将 sql join 查询转换为 sequelizejs 查询
- node.js - SPFX 站点(SharePoint 2016 本地站点与反应)不断重新加载。该怎么办?
- docker - 使用 ENV 参数设置容器 PATH
- django - 如何在django中借助Forign Key访问其他模型的所有字段
- spring - 如何使用 Spring Pageable 在自定义查询 JPQL 上对多个字段执行排序
- android - Flutter:显示 PDF 封面图片