开发者

Android how to cast as a Button

Hey, So im working on this code and I need to cast a findViewById(R.id.foo) as a Button in a parameter. What would be the least memory consuming way? Or should I change the parameter to take View 开发者_运维百科instead of a Button?


Button fooButton = (Button)findViewById(R.id.foo);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜