Make Tusky a share target for video (#857)

This commit is contained in:
Levi Bard 2018-09-28 17:11:32 +02:00 committed by Konrad Pozniak
parent a4f9aa3f71
commit 4ded425466
2 changed files with 11 additions and 1 deletions

View file

@ -63,11 +63,21 @@
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="image/*" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="video/*" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND_MULTIPLE" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="image/*" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND_MULTIPLE" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="video/*" />
</intent-filter>
</activity>
<activity
android:name=".ViewVideoActivity"

View file

@ -562,7 +562,7 @@ public final class ComposeActivity
* instance state will be re-queued. */
String type = intent.getType();
if (type != null) {
if (type.startsWith("image/")) {
if (type.startsWith("image/") || type.startsWith("video/")) {
List<Uri> uriList = new ArrayList<>();
if (intent.getAction() != null) {
switch (intent.getAction()) {