BubbleRelativeLayout.java 文件源码

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

项目:BubblePopupWindow 作者:
@Override
protected void onDraw(Canvas canvas) {

    final float width = canvas.getWidth();
    final float height = canvas.getHeight();

    mPath.rewind();
    mPath.addRoundRect(new RectF(PADDING, PADDING, width - PADDING, height - PADDING), CORNER_RADIUS, CORNER_RADIUS, Direction.CW);
    mPath.addPath(mBubbleLegPrototype, renderBubbleLegMatrix(width, height));

    canvas.drawPath(mPath, mPaint);
    canvas.scale((width - STROKE_WIDTH) / width, (height - STROKE_WIDTH) / height, width / 2f, height / 2f);

    canvas.drawPath(mPath, mFillPaint);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号