我对findviewbyid有点困惑。只是想给出一个简短的解释,如果有任何错误,请检阅它们。findviewbyid函数怎么样
class test
{
Button btes;
public void OnCreate(Bundle savedIntasnceState);
super.OnCreate(savedInstanceState);
btes = (Button)findViewById(R.id.button);
}
这是否意味着findViewById返回对Android.Widget.Button的View对象和实例的引用。 Android.widget.button扩展了findViewById。
问题: 1.上述说明是否正确。如果不是,那么正确的说法是什么。 2.任何人都可以提供视图类的findViewById函数的源代码 3.什么是R.java中的那些十六进制数字。 a)
有没有必要要求在SO中定义一种方法。你可以去[developer.android.com](https://developer.android.com/reference/android/app/Activity.html#findViewById(int))来学习这些。您也可以按ctrl +右键单击该方法以查看Android Studio中的方法实现和定义。 – Blasanka