Android Open Source - NPlayer Code Utils






From Project

Back to project page NPlayer.

License

The source code is released under:

Apache License

If you think the Android project NPlayer listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.qinxiandiqi.utils;
/*from   w w  w  .  j ava  2s.c  o  m*/
import java.util.List;

import com.qinxiandiqi.adapter.MusicAdapter;
import com.qinxiandiqi.adapter.VideoAdapter;
import com.qinxiandiqi.bean.MusicFile;
import com.qinxiandiqi.bean.VideoFile;

public class CodeUtils {
  
  public static final String SEARCHTAG = "SearchTag";
  public static final String MAINTAG = "MainTag";
  
//  ???????
  public static final String PREFERENCES = "qinxiandiqi";
  public static final String LASTIDOFMUSIC = "lastidofmusic";
  public static final String LASTIDOFVIDEO = "lastidofvideo";
  public static final String LASTMUSICMODEL = "lastmodelofmusic";
  public static final String LASTVIDEOMODEL = "lastmodelofvideo";
  
//  ???id
  public static final String MUSICTAB = "musicTab";
  public static final String VIDEOTAB = "videoTab";
  
//  ???????????
  public static final int SEARCHREQUESTCODE = 10;
  public static final int SEARCHRESULTCODE = 10;
  public static final String SEARCHPATHFOREXTRA = "searchpath";
  public static final String SEARCHPATHLIST = "searchpathlist";

//  ????????
  public static final int START = 0;            //??
  public static final int STOP = 1;        //????
  public static final int PAUSE = 2;        //????
  public static final int PLAYING = 3;      //???
  public static final int FASTFORWARD = 4;    //??
  public static final int REWIND = 5;        //??
  public static final int NEXTONE = 6;      //???
  public static final int FORWARDONE = 7;      //???
  public static final int NOTFOUNDFILE = 8;    //???????
  public static final int CUTETONEXT = 9;         //???????
  public static final int NOTNEXTONE = -1;    //??????
  
//  ?????
  public static final int LISTLOOP = 20;       //????
  public static final int SINGLECYCLE = 21;     //??????
  public static final int RANDOM = 22;       //?????
  public static final int ORDERPLAY = 23;       //?????
  public static final int SINGLEPLAY = 24;       //??????
  
//  ?????action
  public static final String MUSICACTION = "com.qinxiandiqi.nplay.MusicActivity";
  public static final String COREACTION = "com.qinxiandiqi.nplay.MainActivity";
  public static final String MUSICSERVICEACTION = "com.qinxiandiqi.service.MusicService";
  
//  intent??
  public static final String MEDIAOPCODE = "MediaOpcode";
  public static final String NEXTID = "nextID";
  
//  ???????
  public static final int STEPSIZE = 5000;
  
  public static String mainTab = MUSICTAB;
  
//  ??mediaPlayer????????????????
  public static boolean hadLoadMusic = false;
  
//  ????????
  public static List<MusicFile> musicFileList;
  public static List<VideoFile> videoFileList;
  public static MusicAdapter musicAdapter;
  public static VideoAdapter videoAdapter;
  
//  ????????????
  public static int playingMusic = NOTNEXTONE;
  public static int playingVideo = NOTNEXTONE;
  public static int playingMusicState = PAUSE;
  public static int playingVideoState = PAUSE;
  public static int playingMusicModel = LISTLOOP;
  public static int playingVideoModel = LISTLOOP;
  
//  ??????
  public static int forwardMusic = NOTNEXTONE;
  
//  ????????????
  public static int musicListLength;
  public static int videoListLength;
}




Java Source Code List

com.qinxiandiqi.adapter.MusicAdapter.java
com.qinxiandiqi.adapter.VideoAdapter.java
com.qinxiandiqi.bean.MediaFile.java
com.qinxiandiqi.bean.MusicFile.java
com.qinxiandiqi.bean.VideoFile.java
com.qinxiandiqi.nplayer.MainActivity.java
com.qinxiandiqi.nplayer.MusicActivity.java
com.qinxiandiqi.nplayer.SearchActivity.java
com.qinxiandiqi.nplayer.VideoActivity.java
com.qinxiandiqi.service.MusicService.java
com.qinxiandiqi.utils.AdapterUtils.java
com.qinxiandiqi.utils.CodeUtils.java
com.qinxiandiqi.utils.FileUtils.java
com.qinxiandiqi.utils.MediaUtils.java
com.qinxiandiqi.utils.PlayingUtils.java
com.qinxiandiqi.utils.PreferenceUtils.java
com.qinxiandiqi.utils.XMLUtils.java