android-smart-image-view-master开源框架的使用
2015-01-25 21:08
453 查看
利用smart-image-view-master能很容易的查看一个网络上面图片
<com.loopj.android.image.SmartImageView
android:layout_weight="1000"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/iv"
/>
<EditText
android:id="@+id/et"
android:singleLine="true"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:hint="请输入网址"
android:text="http://img.uutuu.com/data6/a/ph/large/100402/78d0cf45d94b36fe134c037bfe9c8519.jpg?1270184574"
/>
<Button
android:onClick="play"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="打开图片"
/>
<com.loopj.android.image.SmartImageView
android:layout_weight="1000"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/iv"
/>
<EditText
android:id="@+id/et"
android:singleLine="true"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:hint="请输入网址"
android:text="http://img.uutuu.com/data6/a/ph/large/100402/78d0cf45d94b36fe134c037bfe9c8519.jpg?1270184574"
/>
<Button
android:onClick="play"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="打开图片"
/>
public class MainActivity extends Activity { private EditText ed; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ed=(EditText)findViewById(R.id.et); } public void play(View view){ SmartImageView iv=(SmartImageView)findViewById(R.id.iv); iv.setImageUrl(ed.getText().toString(), R.drawable.ic_launcher, R.drawable.ic_launcher); }
相关文章推荐
- android-smart-image-view-master开源框架的使用
- 在使用Android-Universal-Image-Loader-master这个开源的图片缓存框架的时候,在下拉刷新时,出现闪烁的解决方案
- 实验:android案例——新闻客户端(使用开源项目AsyncHttpClient和SmartImageView)
- Android图像开源框架--SmartImageView
- smart-imageview开源框架的使用
- Android开源框架----1. SmartImageView图像视图
- android开源系列:CircleImageView自定义圆形控件的使用
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- 转:Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android框架——SmartImageView
- Android--Android图像开源视图:SmartImageView
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android图像开源视图:SmartImageView
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android Smart Image View使用方法--从url获取图片或从通讯录获取图片,支持缓存
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用
- Android 开源框架Universal-Image-Loader完全解析(一)--- 基本介绍及使用