logo       

[android-developers] Re: How To Keep ListView Header From Scrolling With Li: msg#04216

AndroidDevelopers

Subject: [android-developers] Re: How To Keep ListView Header From Scrolling With ListView Content


I have similar issue with TableLayout. There must be some mechanism to
define non scrolling header row. If I took out my header row from
ScrollView+TableLayout and define it in new layout than the columns
are not aligned.


Regards,
Atif

On Jun 26, 3:35 am, Mike <MichaelDouglasKra...@xxxxxxxxx> wrote:
> I use the same view for my rows as I do my table header, so in order
> for them to size correctly (make sure the columns in the header line
> up with the column in the rows), they have to be within the same
> container to have the same width, correct?  That's all I meant by
> needing to be in the same ViewGroup.
>
> - Mike
>
> On Jun 25, 9:54 am, Marco Nelissen <marc...@xxxxxxxxxxx> wrote:
>
> > On Thu, Jun 25, 2009 at 8:46 AM, Mike <MichaelDouglasKra...@xxxxxxxxx>wrote:
>
> > > Thanks guys.  This does work provided the ListView and the header View
> > > are within the same parent ViewGroup.
>
> > Can you give an example of when they would not be?
>
> > > I would, however, like to request that the ListView be enhanced with
> > > two new methods:
>
> > > void addHeaderView(View v, Object data, boolean isSelectable, boolean
> > > scrollsWithContent)
> > > void addFooterView(View v, Object data, boolean isSelectable, boolean
> > > scrollsWithContent)
>
> > > This would allow a dev to leave management of the headers and footers
> > > entirely with the ListView and provide the ability to have "sticky"
> > > headers and footers that are owned by the ListView.
>
> > What's the advantage of this over putting your headerview above the ListView
> > in a LinearLayout?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@xxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
android-developers-unsubscribe@xxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | Mail Home | sitemap | FAQ | advertise