List of utility methods to do ViewGroup Set
void | layoutChildAbsoluteCenter(ViewGroup parent, View child, int tWidth, int tHeight) layout Child Absolute Center int w, h, x, y;
w = child.getMeasuredWidth();
h = child.getMeasuredHeight();
x = centerSize(tWidth, w);
y = centerSize(tHeight, h);
child.layout(x, y, x + w, y + h);
|
void | setReadingFontOnChildren(ViewGroup container) set Reading Font On Children Typeface font = Typeface.createFromAsset(container.getContext() .getAssets(), "Palatino.ttc"); View this_view; for (int x = 0; x < container.getChildCount(); x++) { this_view = container.getChildAt(x); if (this_view.getTag() != null) { if (this_view.getTag().toString().compareTo("custom_font") == 0) { ((TextView) this_view).setTypeface(font, ... |
void | setSelected(ViewGroup viewGroup, boolean selected) set Selected for (int i = 0; i < viewGroup.getChildCount(); i++) { viewGroup.getChildAt(i).setSelected(selected); |
void | disableView(ViewGroup rootView, float alpha) Disable all the childs of the selected root view int count = rootView.getChildCount(); View v; for (int i = 0; i < count; i++) { v = rootView.getChildAt(i); if (v != null) { if (v instanceof ViewGroup) disableView((ViewGroup) v, alpha); if (Build.VERSION.SDK_INT > Build.VERSION_CODES.FROYO) ... |