android ImageSwitcher的使用
来源:互联网 发布:数据分析师招聘信息 编辑:程序博客网 时间:2024/06/11 21:07
ImageSwitcher is = (ImageSwitcher) findViewById(R.id. is );
//设置图片动画
is.setInAnimation(AnimationUtils. loadAnimation( this, R.anim.in ));is.setOutAnimation(AnimationUtils. loadAnimation( this, R.anim.out ));
is.setFactory( new ViewFactory() {
@Override
public View makeView() {
ImageView iv = new ImageView(MainActivity.this );
iv.setBackgroundColor(Color. RED);
iv.setScaleType(ScaleType. FIT_CENTER);
iv.setLayoutParams( new ImageSwitcher.LayoutParams(
ImageSwitcher.LayoutParams. WRAP_CONTENT,
ImageSwitcher.LayoutParams. WRAP_CONTENT));
return iv;
}
});
通过 is.setImageResource(图片资源id);设置显示的图片
0 0
- android ImageSwitcher的使用
- android ImageSwitcher的使用
- Android中Gallery和ImageSwitcher的使用
- Android中Gallery和ImageSwitcher的使用
- Android 中textSwitcher与imageSwitcher的使用
- Android基础总结五:ImageSwitcher的使用
- Android的ImageSwitcher效果
- android ImageSwitcher的用法
- Android ImageSwitcher的用法!
- ImageSwitcher的使用
- ImageSwitcher的使用
- ImageSwitcher的使用
- ImageSwitcher的使用
- ImageSwitcher的使用
- ImageSwitcher的使用
- imageSwitcher的使用
- ImageSwitcher的使用
- android中画廊视图Gallery和ImageSwitcher组件的使用
- 大量数据的链接
- 如何学习数据挖掘
- 创建Class对象的4中方式
- Node.js learnyounode #6 MAKE IT MODULAR 题目和答案
- shell 中 grep、sed、awk 命令
- android ImageSwitcher的使用
- cannot open shared object file问题解决办法
- 算法学习(3)分治策略(棋盘覆盖)
- HDU 4553 线段树双关键字区间合并
- Oj2-重复数字中寻找破坏重复次数的那个
- 虚拟机下进行串口调试硬件
- 查看私有方法
- 四、Linux系统编程-文件和IO(二)文件的读写
- 矩阵的逆