如何为所有api设置壁纸而不拉伸

发布于 2024-12-21 13:06:27 字数 330 浏览 4 评论 0原文

我想通过单击按钮来设置壁纸。在这个示例中,我该如何修复api 上发生的拉伸大于 4 ?另外,还有其他方法可以为 7 之前的 api 设置壁纸吗?因为 context.getWallpaper(); 函数似乎已被弃用,并且 WallPaperManager 类不存在。我应该制作一个带有 api < 的应用程序版本吗? 4 以及带有 api > 的版本4 ?

I want to set the wallpaper by clicking a button. In this example, how can I fix the stretching that occurs on api greater than 4 ? Also, is there another method to set the wallpaper for api older than 7? Because the context.getWallpaper(); function seems to be deprecated, and the WallPaperManager class doesn't exist. Should I make a version of app with api < 4 and a version with api > 4 ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文