feat: implemented last set filter as default grouping for downloaded tracks

This commit is contained in:
antonio 2023-08-12 11:17:46 +02:00
parent 01e5917642
commit 4a99c7e9b1
3 changed files with 25 additions and 1 deletions

View file

@ -12,6 +12,7 @@ import com.cappielloantonio.tempo.model.DownloadStack;
import com.cappielloantonio.tempo.repository.DownloadRepository;
import com.cappielloantonio.tempo.subsonic.models.Child;
import com.cappielloantonio.tempo.util.Constants;
import com.cappielloantonio.tempo.util.Preferences;
import java.util.ArrayList;
import java.util.List;
@ -30,7 +31,7 @@ public class DownloadViewModel extends AndroidViewModel {
downloadRepository = new DownloadRepository();
initViewStack(new DownloadStack(Constants.DOWNLOAD_TYPE_TRACK, null));
initViewStack(new DownloadStack(Preferences.getDefaultDownloadViewType(), null));
}
public LiveData<List<Child>> getDownloadedTracks(LifecycleOwner owner) {