mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
Make sequence numbers work for multiple uploads
This commit is contained in:
parent
0fe1ef73e5
commit
da3e40b791
2 changed files with 4 additions and 2 deletions
|
|
@ -148,10 +148,12 @@ public class MultipleShareActivity extends AuthenticatedActivity {
|
|||
|
||||
if(intent.getAction() == Intent.ACTION_SEND_MULTIPLE) {
|
||||
ArrayList<Uri> urisList = intent.getParcelableArrayListExtra(Intent.EXTRA_STREAM);
|
||||
for(Uri uri: urisList) {
|
||||
for(int i=0; i < urisList.size(); i++) {
|
||||
Contribution up = new Contribution();
|
||||
Uri uri = urisList.get(i);
|
||||
up.setLocalUri(uri);
|
||||
up.setTag("mimeType", intent.getType());
|
||||
up.setTag("sequence", i);
|
||||
photosList.add(up);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ public class MultipleUploadListFragment extends SherlockFragment {
|
|||
Boolean isDirty = (Boolean)up.getTag("isDirty");
|
||||
if(isDirty == null || !isDirty) {
|
||||
if(!TextUtils.isEmpty(charSequence)) {
|
||||
up.setFilename(charSequence.toString() + " - " + i);
|
||||
up.setFilename(charSequence.toString() + " - " + ((Integer)up.getTag("sequence") + 1));
|
||||
} else {
|
||||
up.setFilename("");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue