滑动/拖动以关闭RecyclerView

时间:2017-11-30 19:40:40

标签: android android-recyclerview viewdraghelper

我正在寻找一种方法来在new Vue({ el: '#messages', data: { participants: [], active_conversation: '', messages: [] }, methods: { async getParticipants (id) { var response = await this.$http.post('message/get-participants') this.participants = response.data.participants if (id) this.getConversationMessages(id) }, async getConversationMessages (id) { var response = this.$http.post('message/get-messages/' + id) if (response.data.status === 'success') { console.log(response.data.messages) this.messages = response.data.messages; } } }, created () { this.getParticipants(getUrlParameterByName('conversation_id')) } })滚动超出界限时解除它。效果类似于谷歌地图。

我有RecyclerView顶部填充,因此滚动内容在视觉上正常工作,但当我向下滚动到RecyclerView顶部时,我想开始拖动整个RecyclerView并最终隐藏它。

这是否可以通过RecyclerView以某种方式以编程方式拦截触摸并开始拖动它来实现,我一直试图强制拖动但没有成功。

感谢。

0 个答案:

没有答案
相关问题