How to get screen display metrics in application class

You can also try this:

WindowManager wm = (WindowManager) getSystemService(WINDOW_SERVICE);
final DisplayMetrics displayMetrics = new DisplayMetrics();
wm.getDefaultDisplay().getMetrics(displayMetrics);
int height = displayMetrics.heightPixels;
int width = displayMetrics.widthPixels;

Here, Context.getResource()

DisplayMetrics dm = getResources().getDisplayMetrics(); 
int densityDpi = dm.densityDpi;

Try this:

Display display = getWindowManager().getDefaultDisplay();
Log.e("", "" + display.getHeight() + " " + display.getWidth());