Present in both answers;Present only in the new answer;Present only in the old answer;
I think This May Help you !!! DisplayMetrics dimension = new DisplayMetrics(); getWindowManager().getDefaultDisplay().getMetrics(dimension); int w = dimension.widthPixels; int h = dimension.heightPixels;
DisplayMetrics dimension = new DisplayMetrics(); getWindowManager().getDefaultDisplay().getMetrics(dimension); int width = dimension.widthPixels; int height = dimension.heightPixels;
Present in both answers;Present only in the new answer;Present only in the old answer;