build: change of package name

This commit is contained in:
antonio 2023-06-17 15:30:23 +02:00
parent 49afdbe4eb
commit b76a38cb30
274 changed files with 1981 additions and 2161 deletions

View file

@ -0,0 +1,37 @@
package com.cappielloantonio.tempo.viewmodel;
import android.app.Application;
import androidx.annotation.NonNull;
import androidx.lifecycle.AndroidViewModel;
import androidx.lifecycle.MutableLiveData;
import com.cappielloantonio.tempo.repository.DirectoryRepository;
import com.cappielloantonio.tempo.subsonic.models.Indexes;
import com.cappielloantonio.tempo.subsonic.models.MusicFolder;
public class IndexViewModel extends AndroidViewModel {
private final DirectoryRepository directoryRepository;
private MusicFolder musicFolder;
private MutableLiveData<Indexes> indexes = new MutableLiveData<>(null);
public IndexViewModel(@NonNull Application application) {
super(application);
directoryRepository = new DirectoryRepository();
}
public MutableLiveData<Indexes> getIndexes() {
return directoryRepository.getIndexes(null, null);
}
public String getMusicFolderName() {
return musicFolder != null ? musicFolder.getName() : "";
}
public void setMusicFolder(MusicFolder musicFolder) {
this.musicFolder = musicFolder;
}
}