- 博客(4)
- 资源 (1)
- 收藏
- 关注
原创 #define S(a, b) a##b
#define S(a, b) a##b int main() { printf("%d\n", S(3, 4)); printf("%d\n", S(5, 6)); return 0; } 这个程序输出什么? 输出34 56 原来##居然就是连接符的意思,记之
2015-11-13 09:37:46
1555
原创 switch中出错:case expressions must be constant expressions
switch(v.getId()) { case R.id.old_color_panel: break; case R.id.new_color_panel: if (mListener != null) { mListener.onColorChanged(mNewColor.getColor()); } break; } dismiss(); 如上的一段code,编译时出
2015-06-15 10:59:47
781
原创 The method findViewById(int) is undefined for the type FragmentHome报错
很简单的一个TextView初始化,但是去会报错,解决方法加上view,如下: View view = inflater.inflate(R.layout.home_index, null); //获取数据并且显示 topCity = (TextView)findViewById(R.id.index_top_city); topCity = (TextView)view.f
2015-06-13 22:01:10
2874
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅