功能分类:娱乐
支持平台:Android
运行环境:Android
开发语言:Java
开发工具:Eclipse
源码大小:1.94MB
源码下载地址:http://down.51cto.com/data/1977581
源码简介
主要是模仿天天听音乐,可以实现联网获取歌词和明星写真,摇一摇实现换歌!
源码运行截图
启动首界面
全部歌曲
用户中心
设置
源码片段
- import java.io.File;
- import com.ldw.music.service.ServiceManager;
- import android.app.Application;
- import android.os.Environment;
- public class MusicApp extends Application {
- public static boolean mIsSleepClockSetting = false;
- public static ServiceManager mServiceManager = null;
- private static String rootPath = "/mymusic";
- public static String lrcPath = "/lrc";
- @Override
- public void onCreate() {
- super.onCreate();
- mServiceManager = new ServiceManager(this);
- initPath();
- }
- private void initPath() {
- String ROOT = "";
- if(Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED)) {
- ROOT = Environment.getExternalStorageDirectory().getPath();
- }
- rootPath = ROOT + rootPath;
- lrcPath = rootPath + lrcPath;
- File lrcFile = new File(lrcPath);
- if(lrcFile.exists()) {
- lrcFile.mkdirs();
- }
- }
- }