public int getStatusBarHeight() {
int statusBarHeight= 0;
int resourceId = getResources().getIdentifier("status_bar_height", "dimen", "android");
if (resourceId > 0) {
statusBarHeight= getResources().getDimensionPixelSize(resourceId);
}
Log.d(TAG, "statusBarHeight="+result);
return statusBarHeight;
}
int statusBarHeight= 0;
int resourceId = getResources().getIdentifier("status_bar_height", "dimen", "android");
if (resourceId > 0) {
statusBarHeight= getResources().getDimensionPixelSize(resourceId);
}
Log.d(TAG, "statusBarHeight="+result);
return statusBarHeight;
}