我正在使用以下代码。但是所有方法都返回零值。我知道要获取视图的坐标,我们的视图应该被绘制。这就是为什么我在onResume方法中使用该代码,但仍然无法工作。有什么想法吗?
@Override
public void onResume(){
super.onResume();
System.out.println("Onresume");
System.out.println("tab1 - left" + btn_Tab7 .getLeft());
System.out.println("tab1 - Top" + btn_Tab7.getTop());
System.out.println("tab1 - right" + btn_Tab7.getRight());
System.out.println("tab1 - bottom" + btn_Tab7.getBottom());
}