private void setStatusBar(Fragment targetFragment) {
if (Build.VERSION.SDK_INT >= 21) {
View decorView = getWindow().getDecorView();
if (targetFragment == mIndexMineFragment || targetFragment == mIndexHomeFragment) {
decorView.setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN | View.SYSTEM_UI_FLAG_LAYOUT_STABLE);
getWindow().setStatusBarColor(Color.TRANSPARENT);
} else {
setStatusBarColor(R.color.color_white);
}
}
}