konstantinbueschel
11/18/2016 - 2:38 PM

Set Layout Gravity Programmatically or rather align view at bottom of parent FrameLayout - Source: ((FrameLayout.LayoutParams) view.getLayou

Set Layout Gravity Programmatically or rather align view at bottom of parent FrameLayout - Source: ((FrameLayout.LayoutParams) view.getLayoutParams()).gravity = Gravity.BOTTOM;

((FrameLayout.LayoutParams) view.getLayoutParams()).gravity = Gravity.BOTTOM;

// or on FrameLayout.LayoutParams creation

FrameLayout.LayoutParams params = new FrameLayout.LayoutParams(width != 0 ? width : FrameLayout.LayoutParams.MATCH_PARENT, height, Gravity.BOTTOM);