简体   繁体   中英

Horizontal list view in vertical scroll view in android

I need to implement application like https://play.google.com/store/apps/details?id=com.alphonso.pulse

what i tried is,

   I think they should done through horizontalscrollview/horizontallistview.
   So i integrate horizontal listview through this sample,

https://www.dev-smart.com/archives/34

what i need is,

  • I need to integrate horizontal listview inside the vertical listview

  • I should know how they integrate this idea

Any help should be appreciable.Thanks

Do you need something like this?

<ScrollView>
  <LinearLayout android:orientation="vertical">

    <!-- First row -->
    <HorizontalScrollView>
      <LinearLayout android:orientation="horizontal">
        <!-- Items of this row -->
      </LinearLayout>
    </HorizontalScrollView>

  </LinearLayout>
</ScrollView>

You will need to set appropriate layout attributes and you might want to add titles to the rows. If you have a variable number of rows, you can create them programmatically.

我来晚了,但是你可以用这个.. https://github.com/lucasr/twoway-view

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM