private void doAutoShuffleUpdate(){
  boolean notify=false;
  if (mPlayPos > 10) {
    removeTracks(0,mPlayPos - 9);
    notify=true;
  }
  final int toAdd=7 - (mPlayListLen - (mPlayPos < 0 ? -1 : mPlayPos));
  for (int i=0; i < toAdd; i++) {
    int lookback=mHistory.size();
    int idx=-1;
    while (true) {
      idx=mShuffler.nextInt(mAutoShuffleList.length);
      if (!wasRecentlyUsed(idx,lookback)) {
        break;
      }
      lookback/=2;
    }
    mHistory.add(idx);
    if (mHistory.size() > MAX_HISTORY_SIZE) {
      mHistory.remove(0);
    }
    ensurePlayListCapacity(mPlayListLen + 1);
    mPlayList[mPlayListLen++]=mAutoShuffleList[idx];
    notify=true;
  }
  if (notify) {
    notifyChange(QUEUE_CHANGED);
  }
}

private void doAutoShuffleUpdate ( ) { boolean notify = false ; if ( mPlayPos > 10 ) { removeTracks ( 0 , mPlayPos - 9 ) ; notify = true ; } final int toAdd = 7 - ( mPlayListLen - ( mPlayPos < 0 ? - 1 : mPlayPos ) ) ; for ( int i = 0 ; i < toAdd ; i ++ ) { int lookback = mHistory . size ( ) ; int idx = - 1 ; while ( true ) { idx = mShuffler . nextInt ( mAutoShuffleList . length ) ; if ( ! wasRecentlyUsed ( idx , lookback ) ) { break ; } lookback /= 2 ; } mHistory . add ( idx ) ; if ( mHistory . size ( ) > MAX_HISTORY_SIZE ) { mHistory . remove ( 0 ) ; } ensurePlayListCapacity ( mPlayListLen + 1 ) ; mPlayList [ mPlayListLen ++ ] = mAutoShuffleList [ idx ] ; notify = true ; } if ( notify ) { notifyChange ( QUEUE_CHANGED ) ; } }
creates the party shuffle playlist
