判断横竖屏

Verify Landscape Orientation

public static boolean isLandscape(Context context) {

            int orientation = context.getResources().getConfiguration().orientation;

            boolean result = (orientation == Configuration.ORIENTATION_LANDSCAPE);

 

            return result;

      }

你可能感兴趣的:(判断横竖屏)