BrowserByShow.java 文件源码

java
阅读 34 收藏 0 点赞 0 评论 0

项目:aos-Video 作者:
@Override
protected void setColor(int color) {

    int darkColor = VideoInfoCommonClass.getDarkerColor(color);
    ColorDrawable[] colord = {new ColorDrawable(mLastColor), new ColorDrawable(darkColor)};
    TransitionDrawable trans = new TransitionDrawable(colord);
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN)
        mApplicationFrameLayout.setBackground(trans);
    else
        mApplicationFrameLayout.setBackgroundDrawable(trans);
    trans.startTransition(200);
    mLastColor = darkColor;
    if(Build.VERSION.SDK_INT>=Build.VERSION_CODES.LOLLIPOP) {
        getActivity().getWindow().clearFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
        getActivity().getWindow().addFlags(WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS);
        getActivity().getWindow().setStatusBarColor(VideoInfoCommonClass.getAlphaColor(darkColor, 160));
    }

}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号