Override onDraw() or draw()?

后端 未结 6 988
隐瞒了意图╮
隐瞒了意图╮ 2021-02-18 20:27

My project is based on surfaceView and up until now I\'ve had all of my rendering in onDraw which I am overriding. All seemed to be OK.

However, I\'ve just updated my S

6条回答
  •  时光取名叫无心
    2021-02-18 21:03

    Note that in the case of drawing, overriding draw() and calling super.draw is often used when a ViewGroup wants to draw content over its child views. Content drawn in onDraw will appear under children.

提交回复
热议问题