现在的位置: 首页 > 综合 > 正文

获取status bar 高度

2018年02月10日 ⁄ 综合 ⁄ 共 145字 ⁄ 字号 评论关闭

            Rect statusRect = new Rect();
            getWindow().getDecorView().getWindowVisibleDisplayFrame(statusRect);
            int statusBarHeight = statusRect.top;

抱歉!评论已关闭.