列出sdcard里所有.mp3文件,并且可以点击播放
push songs into sdcard(before you push,you make sure your avd is running,else the operation of push will not work):
adb push f:\music\1.mp3 /sdcard
Step 2: Layout UI desigen:
create two .xml files we called song_item.xml and songlist.xml the code are:
song_item.xml:
<?xml version="1.0" encoding="utf-8"?>
<TextView android:id="@+id/text1" xmlns:android="http://schemas.android.com/apk/res/android"
??? android:layout_width="wrap_content"
??? android:layout_height="wrap_content"/>
songlist.xml:
<?xml version="1.0" encoding="UTF-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
??????? android:orientation="vertical"
??????? android:layout_width="fill_parent"
now u can enjoy? the music.lol~
if u wanna the source code please leave your email address, i will send u!