Android examples for User Interface:Layout
get View Layout Direction
//package com.java2s; import android.os.Build; import android.view.View; public class Main { @SuppressWarnings("") public static int getLayoutDirection(View v) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) { return v.getLayoutDirection(); }/*w ww .j ava 2 s .c om*/ return View.LAYOUT_DIRECTION_LTR; } }