I need get offsetHeight of Vlayout, but until i know that it's drawn. How I can check that, this component is drawn ?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
How I can check that, this component is drawn ?
You can override the onDraw method of Canvas and add some custom functionality there.
@Override
protected void onDraw()
{
super.onDraw();
//your code
}
Alternatively you can add a draw handler to the component:
addDrawHandler(new DrawHandler() {
@Override
public void onDraw(DrawEvent event)
{
//Do stuff
}
});