allow sharing and attaching of multiple files

fixes #3132
This commit is contained in:
Daniel Gultsch 2018-09-12 18:43:14 +02:00
parent d7cdec002c
commit fbc1d242ca
2 changed files with 2 additions and 14 deletions

View File

@ -204,24 +204,11 @@
android:launchMode="singleTop"> android:launchMode="singleTop">
<intent-filter> <intent-filter>
<action android:name="android.intent.action.SEND"/> <action android:name="android.intent.action.SEND"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="text/plain"/>
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="*/*"/>
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND_MULTIPLE"/> <action android:name="android.intent.action.SEND_MULTIPLE"/>
<category android:name="android.intent.category.DEFAULT"/> <category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="image/*"/> <data android:mimeType="*/*"/>
</intent-filter> </intent-filter>
<meta-data <meta-data

View File

@ -1566,6 +1566,7 @@ public class ConversationFragment extends XmppFragment implements EditMessage.Ke
case ATTACHMENT_CHOICE_CHOOSE_FILE: case ATTACHMENT_CHOICE_CHOOSE_FILE:
chooser = true; chooser = true;
intent.setType("*/*"); intent.setType("*/*");
intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
intent.addCategory(Intent.CATEGORY_OPENABLE); intent.addCategory(Intent.CATEGORY_OPENABLE);
intent.setAction(Intent.ACTION_GET_CONTENT); intent.setAction(Intent.ACTION_GET_CONTENT);
break; break;