Android异步加载图片详解之方式二(3)

main.xml如下:

<RelativeLayout 
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent" >
    <ListView 
        android:id="@+id/listView"
        android:layout_width="fill_parent"
        android:layout_height="fill_parent"
     >
        
    </ListView>

</RelativeLayout>


 


listviewitem.xml如下:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="50dip"
    android:orientation="horizontal" >   
    <ImageView 
        android:id="@+id/imageview"
        android:layout_width="50dip" 
        android:layout_height="50dip"     
     />
    
    <TextView 
        android:id="@+id/textView"
        android:layout_width="50dip"
        android:layout_height="50dip"
        android:text="haha"
        android:layout_marginLeft="150dip"
     />  
</LinearLayout>


 

你可能感兴趣的:(Android异步加载图片详解之方式二(3))