/**
* 獲取組件高度(寬度)
*
* @param view
* @return
*/ www.aiwalls.com
public static int getHeight(View view)
{
int w = View.MeasureSpec.makeMeasureSpec(0,
View.MeasureSpec.UNSPECIFIED);
int h = View.MeasureSpec.makeMeasureSpec(0,
View.MeasureSpec.UNSPECIFIED);
view.measure(w, h);
return view.getMeasuredHeight();
}