Send "inserting" message to notifications while committing temp provider.
Right now it says "50%" always, will need to think whether to ditch the percentage completely, or to have the temp app/apk providers emit progress events some how too.
This commit is contained in:
parent
71f641860a
commit
90290f830a
@ -53,6 +53,7 @@ public class RepoUpdater {
|
||||
private static final String TAG = "RepoUpdater";
|
||||
|
||||
public static final String PROGRESS_TYPE_PROCESS_XML = "processingXml";
|
||||
public static final String PROGRESS_COMMITTING = "committing";
|
||||
public static final String PROGRESS_DATA_REPO_ADDRESS = "repoAddress";
|
||||
|
||||
@NonNull
|
||||
|
@ -505,8 +505,6 @@ public class UpdateService extends IntentService implements ProgressListener {
|
||||
@Override
|
||||
public void onProgress(ProgressListener.Event event) {
|
||||
String message = "";
|
||||
// TODO: Switch to passing through Bundles of data with the event, rather than a repo address. They are
|
||||
// now much more general purpose then just repo downloading.
|
||||
String repoAddress = event.getData().getString(RepoUpdater.PROGRESS_DATA_REPO_ADDRESS);
|
||||
String downloadedSize = Utils.getFriendlySize(event.progress);
|
||||
String totalSize = Utils.getFriendlySize(event.total);
|
||||
@ -515,6 +513,9 @@ public class UpdateService extends IntentService implements ProgressListener {
|
||||
case RepoUpdater.PROGRESS_TYPE_PROCESS_XML:
|
||||
message = getString(R.string.status_processing_xml_percent, repoAddress, downloadedSize, totalSize, percent);
|
||||
break;
|
||||
case RepoUpdater.PROGRESS_COMMITTING:
|
||||
message = getString(R.string.status_inserting, 50);
|
||||
break;
|
||||
}
|
||||
sendStatus(this, STATUS_INFO, message, percent);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user