0

I hope I'm not too vague with this question. For some reason I've developed an inordinate fear of being ambiguous with my SO questions :-)

I need to make a design decision and, having just recently started in my Android efforts, I thought I might ask about its potential dangers among those who've been in the trenches for awhile.

I'd like to build a gallery within a gallery. The outer widget views will scroll horizontally, while the inner views--being galleries themselves--will scroll vertically.

Has this been tried/crashed/burned in the past? If so I'll rethink my UI, but I wanted to ask in advance before I spend a lot of time chasing the wrong dog.

Thanks, Jeff

InteXX
  • 6,135
  • 6
  • 43
  • 80

1 Answers1

0

The gallery widget cannot scroll vertically. There's no way to change orientation, it can only be horizontal. You can build it custom, something like attaching image views to list views and such, or you can use something like a wheel scroller, like this one, called android wheel, and do some tweaking to make it look and work the way you want. These two SO posts might help as well, for the vertical aspect.

Lazy load of images in ListView

Vertical gallery in android

Community
  • 1
  • 1
TomHarrigan
  • 618
  • 4
  • 10
  • @TomHarrigan: > The gallery widget cannot scroll vertically < Well that definitely qualifies as a crash-and-burn :-) Thanks for the lead, I'll look very closely at that. – InteXX Jun 15 '11 at 01:09
  • You're welcome, I added a couple of links to related posts that talk about binding ListViews and ImageViews – TomHarrigan Jun 15 '11 at 01:11
  • @TomHarrigan: Yes, that lazy load question has a link to this app: [Shelves](http://code.google.com/p/shelves/). It looks pretty darn good--I'm sure a lot of it's over my head but I'm going to give it a go. – InteXX Jun 15 '11 at 01:36
  • @TomHarrigan: Per [this question](http://stackoverflow.com/questions/3754445/how-to-make-a-2-dimension-image-gallery-with-both-horizontal-and-vertical-scrolli), to your knowledge does the GridView scroll in a similar fashion as the Gallery? IOW, I like the Gallery's snap-to-center behavior. – InteXX Jun 15 '11 at 01:42
  • Sorry, my knowledge regarding GridView is close to non-existent, I'm reading about it now. http://developer.android.com/resources/tutorials/views/hello-gridview.html – TomHarrigan Jun 15 '11 at 02:05
  • @InteXX No, if I remember correctly, the `GridView` is just a special case of a `ListView`, which does no snapping at all. – dmon Jun 15 '11 at 04:09