//是平板返回true 不是平板返回false

public  boolean isTablet(Context context) {

return (context.getResources().getConfiguration().screenLayout & Configuration.SCREENLAYOUT_SIZE_MASK) >= Configuration.SCREENLAYOUT_SIZE_LARGE;

}

05-04 01:48