override onSize(), computescroll() method, then call SetVisiblity(). Would you want to design self scrollView dialog? Please give some code here, it is possible to say something right.
On Fri, Jul 16, 2010 at 5:03 AM, Pepi <[email protected]> wrote: > Hello to all, > > I need to hide/show a Button whether a ScrollView needs to scroll or > not. (The same behavior as the ScrollView's ScrollBar). > > I've done this working with the ScrollView's computeScroll() method, > in order to compare it's height, with the child's one, then according > to that condition hide/show the Button. But I'm facing a repaint issue > since this is made once the layout has been set by > Activity.setContentView(). > > So now I'm trying to inflate the layout that contains this ScrollView, > perform this height comparison before the Activity.setContentView() > it's called. > > The problem is that the LayoutInflater inflates the layout without any > measure (width = 0 and height = 0). > > This is how I'm inflating the layout: > > LayoutInflater inflater = getLayoutInflater(); > LinearLayout layout = (LinearLayout) inflater.inflate(R.layout.main, > null); > > Is there a way to retrieve the Activity's first ViewGroup in order to > inflate my layout with a parent? I think the issue is related with > this. > > Thanks a lot in advance, > > Pepi > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected]<android-developers%[email protected]> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

