支持滑动刷新
即使您的应用会定期自动更新其内容,您也可以允许用户请求手动更新。例如,天气预报应用可让用户按需获取最新预报。为了针对请求更新提供标准的用户体验,Android 平台采用滑动刷新设计模式,可让用户通过纵向滑动触发更新。
下载示例应用:
课程
为应用添加滑动刷新 了解如何在 ListView
或 GridView
中提供滑动刷新支持,以及如何使用操作栏提供更方便访问的刷新选项。 响应刷新请求 了解如何响应滑动刷新手势,以及如何通过操作栏操作执行相同的更新。
Content and code samples on this page are subject to the licenses described in the Content License . Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2020-06-26 UTC.
[{
"type": "thumb-down",
"id": "missingTheInformationINeed",
"label":"没有我需要的信息"
},{
"type": "thumb-down",
"id": "tooComplicatedTooManySteps",
"label":"太复杂/步骤太多"
},{
"type": "thumb-down",
"id": "outOfDate",
"label":"内容需要更新"
},{
"type": "thumb-down",
"id": "translationIssue",
"label":"翻译问题"
},{
"type": "thumb-down",
"id": "samplesCodeIssue",
"label":"示例/代码问题"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"其他"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"易于理解"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"解决了我的问题"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"其他"
}]