Thanks a lot for the code sample. I was overriding the onMeasure()
method to set my preffered size but I was not calling the
setMeasureDimension() method.
On Mar 11, 3:00 pm, acopernicus <[EMAIL PROTECTED]> wrote:
> Thanks Romain Guy,
>
> I used this solution in case anyone else needs it:
>
> private static final int NAV_PANEL_HEIGHT = 50;
> protected void onMeasure(int widthMeasureSpec, int
> heightMeasureSpec) {
> super.onMeasure(widthMeasureSpec, heightMeasureSpec);
> setMeasuredDimension(getMeasuredWidth(), NAV_PANEL_HEIGHT);
> }
>
> I was initially having problems with thewidthbecause I didn't have a
> preferredwidth...just wanted it to be themaxpossible. To resolve
> this, I let the super.onMeasure() method handle determining thewidth() &
> height() & then override the height afterwards. I'm curious
> to eventually learn how the super.onMeasure() method is determining
> the availablewidthas the passed in widthMeasureSpec is themaxint
> size (>100,000).
>
> Thanks,
> Anthony
--~--~---------~--~----~------------~-------~--~----~
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]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---