How do I reposition views at runtime? In activity onCreate when all
views are set all views sizes are 0. If I could somehow subclass
activity view loaded from resources I could probably override view's
onFinishInflate() and reposition all views after they all have been
set and inflated.
--
You
How do I reposition views at runtime?
The same way you position them in the first place -- by manipulating their
layout rules (e.g., android:layout_centerInParent). You do this via
calling getLayoutParams() on your View, casting it to an appropriate type
(e.g., RelativeLayout.LayoutParams),
You're trying to reposition your view right after inflating them ... ?
Why not just set them up in XML the way you actually want them to begin with
...?
-
TreKing - Chicago transit tracking app for
3 matches
Mail list logo