使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
本页面概要介绍了如何将 Preference 库用于其他受支持的设备类型。
Android TV
您应该使用 AndroidX Leanback Preference 库来构建 Android TV 设备上的设置。由于 Leanback Preference 库与此库有很多相同的概念,因此您可以使用很多相同的属性来自定义设置屏幕。
本页面上的内容和代码示例受内容许可部分所述许可的限制。Java 和 OpenJDK 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-27。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-07-27。"],[],[],null,["# Handle other form factors\nPart of [Android Jetpack](/jetpack).\n==============================================================\n\nThis topic outlines using the Preference Library with other supported form\nfactors.\n\nAndroid TV\n----------\n\nYou should use the\n[AndroidX Leanback Preference Library](/reference/kotlin/androidx/leanback/preference/package-summary)\nfor building settings on Android TV devices. As the Leanback Preference Library\nshares many of the same concepts as this library, you can use many of the same\nattributes to customize your settings screens."]]