LinearLayout is not a FrameLayout. I just remembered that ScrollView *is* a FrameLayout, my bad. The layout params of the ScrollView's child should be ScrollView.LayoutParams (or FrameLayout.LayoutParams.) A child must always use the layout params type declared in its parent.
On Sun, Mar 25, 2012 at 1:46 PM, Jim Graham <spooky1...@gmail.com> wrote: > On Sun, Mar 25, 2012 at 01:35:14PM -0700, Romain Guy wrote: >> It might now be a FrameLayout but a subclass of a FrameLayout. You can >> see that the problem happens inside a ScrollView. What ScrollViews do >> you have and what do you put in them? > > I should have mentioned---it happened before I put in the ScrollView, > too. > > But to answer your question, as per the ScrollView docs, it can only wrap > one item, and that's a LinearLayout. > > So is LinearLayout a subclass of FrameLayout, then? I would never have > guessed that (and if it's in the docs, I never saw it). So should I > change the cast for the LinearLayout params to FrameLayout, then? > And do I need to import android.widget.FrameLayout? > > Sorry if any of these are stupid questions---I'm in unexplored territory > with these problems, and have been for (how many weeks has this been > driving me crazy, going from one set of documentation material to > another, and another, and another, and ... ad nauseum?). As I said in > my first post, I finally gave up and had to post here. > > Thanks, > --jim > > PS: no need to CC me...gmail nukes the duplicate copy when it sees > the duplicate Message-ID...and it'd still end up in this mbox > file instead of in /var/mail thanks to my procmail filters > that redirect all from this group here. :-) > > -- > THE SCORE: ME: 2 CANCER: 0 > 73 DE N5IAL (/4) MiSTie #49997 < Running FreeBSD 7.0 > > spooky1...@gmail.com ICBM/Hurr.: 30.44406N 86.59909W > > "Now what *you* need is a proper pint of porter poured in a proper > pewter porter pot.." --Peter Dalgaard in alt.sysadmin.recovery > > Android Apps Listing at http://www.jstrack.org/barcodes.html > > -- > 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@googlegroups.com > To unsubscribe from this group, send email to > android-developers+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- Romain Guy Android framework engineer romain...@android.com -- 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@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en