用形象的Andorid水平列表视图不能滚动 [英] can not scroll with image on Andorid horizontal list view

查看:126
本文介绍了用形象的Andorid水平列表视图不能滚动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好我现在用的水平列表视图在这个库 https://github.com/MeetMe

和我用它包含的ImageButton和TextView的适配器 但是当我从图像滚动它不会滚动 我不知道为什么。

你能帮助我吗?

main.xml中

 < com.meetme.android.horizo​​ntallistview.Horizo​​ntalListView
机器人:ID =@ + ID / hlvCustomListFriends
机器人:layout_width =WRAP_CONTENT
机器人:layout_height =200dp
机器人:layout_alignParentLeft =真
机器人:layout_below =@ + ID / shared_friends
机器人:paddingBottom会=10dp/>
 

adapter.xml

 < RelativeLayout的的xmlns:机器人=htt​​p://schemas.android.com/apk/res/android
的xmlns:工具=htt​​p://schemas.android.com/tool​​s
机器人:layout_width =match_parent
机器人:layout_height =match_parent
机器人:方向=垂直
机器人:layout_margin =5DP>

<的ImageButton
    机器人:ID =@ + ID / imageButton_aaa
    机器人:layout_width =80dp
    机器人:layout_height =80dp
    机器人:layout_alignParentTop =真
    机器人:layout_centerHorizo​​ntal =真
    机器人:背景=@空
    机器人:填充=5DP
    机器人:SRC =@可绘制/ icon_editbar_profile/>

<的TextView
    机器人:ID =@ + ID / textView_aaa
    机器人:layout_width =80dp
    机器人:layout_height =match_parent
    机器人:layout_alignParentBottom =真
    机器人:layout_below =@ + ID / imageButton_aaa
    机器人:layout_centerHorizo​​ntal =真
    机器人:重力=center_horizo​​ntal
    机器人:文本=DD
    机器人:textAppearance =机器人:ATTR / textAppearanceMedium/>

< / RelativeLayout的>
 

解决方案

我一直在用,你正在使用,得到了同样的问题,如你是同一个库,它也将在库中,你所使用的限制提到所以这将是更好地转移到另一个我张贴,将工作就像魅力的链接。

使用该水平列表视图我用这一个,它有适当的实施甚至scrol listners可以实现像一个魅力的作品对我来说。

<一个href="https://github.com/sephiroth74/HorizontalVariableListView">https://github.com/sephiroth74/HorizontalVariableListView

有关日食

<一个href="https://mega.co.nz/#!REAnkAwb!NH9JYrVJkthJAFdMsTGQHYOGmLYCW-RLAUPX1b2PFBY">https://mega.co.nz/#!REAnkAwb!NH9JYrVJkthJAFdMsTGQHYOGmLYCW-RLAUPX1b2PFBY 因为作者没有发布使用Eclipse的文件,乌默尔发文件,我把它上传到Disonash(德文)MEGA空间,希望每一位可以使用这个,如果你需要它。

Hi I am using the horizontal list view in this library https://github.com/MeetMe

and I used the adapter which contains imagebutton and textview but when I scroll from the image it won't scroll and I don't know why

can you help me?

main.xml

<com.meetme.android.horizontallistview.HorizontalListView
android:id="@+id/hlvCustomListFriends"
android:layout_width="wrap_content"
android:layout_height="200dp" 
android:layout_alignParentLeft="true"
android:layout_below="@+id/shared_friends"
android:paddingBottom="10dp"/>

adapter.xml

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" 
android:layout_margin="5dp">

<ImageButton
    android:id="@+id/imageButton_aaa"
    android:layout_width="80dp"
    android:layout_height="80dp"
    android:layout_alignParentTop="true"
    android:layout_centerHorizontal="true"
    android:background="@null"
    android:padding="5dp"
    android:src="@drawable/icon_editbar_profile" />

<TextView
    android:id="@+id/textView_aaa"
    android:layout_width="80dp"
    android:layout_height="match_parent"
    android:layout_alignParentBottom="true"
    android:layout_below="@+id/imageButton_aaa"
    android:layout_centerHorizontal="true"
    android:gravity="center_horizontal"
    android:text="dd"
    android:textAppearance="?android:attr/textAppearanceMedium" />

</RelativeLayout>

解决方案

I have been using the same library which you are using and got same issues like you are and it is also mentioned in the limitations of the library which you are using so it would be better to move on to another i posted a link that would work like charm.

Use this Horizontal Listview i am using this one and it has proper implementation even the scrol listners can be implemented works like a charms for me.

https://github.com/sephiroth74/HorizontalVariableListView

for eclipse

https://mega.co.nz/#!REAnkAwb!NH9JYrVJkthJAFdMsTGQHYOGmLYCW-RLAUPX1b2PFBY because the author didn't post a eclipse used file, Umer made the file and I upload it to Disonash(Devon)MEGA space, hope every can use this if you need it.

这篇关于用形象的Andorid水平列表视图不能滚动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆