mirror of
https://github.com/antebudimir/tempus.git
synced 2026-01-01 18:03:33 +00:00
Renamed DownloaderTracker to DownloaderManager
This commit is contained in:
parent
134d4e33e5
commit
e4d09f3bc0
4 changed files with 14 additions and 13 deletions
|
|
@ -16,16 +16,16 @@ import androidx.media3.session.SessionToken;
|
|||
|
||||
import com.cappielloantonio.play.R;
|
||||
import com.cappielloantonio.play.service.DownloaderService;
|
||||
import com.cappielloantonio.play.service.DownloaderTracker;
|
||||
import com.cappielloantonio.play.service.DownloaderManager;
|
||||
import com.cappielloantonio.play.service.MediaService;
|
||||
import com.cappielloantonio.play.util.DownloadUtil;
|
||||
import com.google.common.util.concurrent.ListenableFuture;
|
||||
|
||||
public class BaseActivity extends AppCompatActivity implements DownloaderTracker.Listener {
|
||||
public class BaseActivity extends AppCompatActivity implements DownloaderManager.Listener {
|
||||
private static final String TAG = "BaseActivity";
|
||||
|
||||
private ListenableFuture<MediaBrowser> mediaBrowserListenableFuture;
|
||||
private DownloaderTracker downloaderTracker;
|
||||
private DownloaderManager downloaderManager;
|
||||
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
|
|
@ -102,7 +102,7 @@ public class BaseActivity extends AppCompatActivity implements DownloaderTracker
|
|||
|
||||
@SuppressLint("UnsafeOptInUsageError")
|
||||
private void initializeDownloader() {
|
||||
downloaderTracker = DownloadUtil.getDownloadTracker(this);
|
||||
downloaderManager = DownloadUtil.getDownloadTracker(this);
|
||||
|
||||
try {
|
||||
DownloadService.start(this, DownloaderService.class);
|
||||
|
|
@ -112,10 +112,10 @@ public class BaseActivity extends AppCompatActivity implements DownloaderTracker
|
|||
}
|
||||
|
||||
private void addDownloadListener() {
|
||||
downloaderTracker.addListener(this);
|
||||
downloaderManager.addListener(this);
|
||||
}
|
||||
|
||||
private void removeDownloadListener() {
|
||||
downloaderTracker.removeListener(this);
|
||||
downloaderManager.removeListener(this);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue