aboutsummaryrefslogtreecommitdiffstats
path: root/OpenKeychain/src/main/java
diff options
context:
space:
mode:
authorVincent Breitmoser <valodim@mugenguild.com>2015-09-11 04:59:00 +0200
committerVincent Breitmoser <valodim@mugenguild.com>2015-09-11 04:59:00 +0200
commit0d46a589e5161aeb762bc7eab2a71b69d33fedce (patch)
tree21b5fcd6ef06093e5019b6b448249a1985591087 /OpenKeychain/src/main/java
parentfd6141f0d2564eee1e6c87fe6db5bf3bbb1c4bcf (diff)
downloadopen-keychain-0d46a589e5161aeb762bc7eab2a71b69d33fedce.tar.gz
open-keychain-0d46a589e5161aeb762bc7eab2a71b69d33fedce.tar.bz2
open-keychain-0d46a589e5161aeb762bc7eab2a71b69d33fedce.zip
no chooser before DisplayTextActivity, can select from there (#1524)
Diffstat (limited to 'OpenKeychain/src/main/java')
-rw-r--r--OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/DecryptListFragment.java21
1 files changed, 4 insertions, 17 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/DecryptListFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/DecryptListFragment.java
index 92470218b..ddaf40010 100644
--- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/DecryptListFragment.java
+++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/DecryptListFragment.java
@@ -28,7 +28,6 @@ import android.app.Activity;
import android.content.ClipDescription;
import android.content.Context;
import android.content.Intent;
-import android.content.pm.LabeledIntent;
import android.content.pm.ResolveInfo;
import android.graphics.Bitmap;
import android.graphics.Point;
@@ -37,7 +36,6 @@ import android.graphics.drawable.Drawable;
import android.net.Uri;
import android.os.AsyncTask;
import android.os.Bundle;
-import android.os.Parcelable;
import android.support.v7.widget.DefaultItemAnimator;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
@@ -57,7 +55,6 @@ import android.widget.ViewAnimator;
import org.openintents.openpgp.OpenPgpMetadata;
import org.openintents.openpgp.OpenPgpSignatureResult;
-import org.sufficientlysecure.keychain.BuildConfig;
import org.sufficientlysecure.keychain.Constants;
import org.sufficientlysecure.keychain.R;
import org.sufficientlysecure.keychain.operations.results.DecryptVerifyResult;
@@ -435,21 +432,11 @@ public class DecryptListFragment
return;
}
- Intent intent = new Intent(Intent.ACTION_VIEW);
+ Intent intent = new Intent(activity, DisplayTextActivity.class);
+ intent.setAction(Intent.ACTION_VIEW);
intent.setDataAndType(outputUri, metadata.getMimeType());
-
- // for result so we can possibly get a snackbar error from internal viewer
- LabeledIntent internalIntent = new LabeledIntent(
- new Intent(intent)
- .setClass(activity, DisplayTextActivity.class)
- .putExtra(DisplayTextActivity.EXTRA_METADATA, result),
- BuildConfig.APPLICATION_ID, R.string.view_internal, R.mipmap.ic_launcher);
-
- Intent chooserIntent = Intent.createChooser(intent, getString(R.string.intent_show));
- chooserIntent.putExtra(Intent.EXTRA_INITIAL_INTENTS,
- new Parcelable[] { internalIntent });
-
- activity.startActivity(chooserIntent);
+ intent.putExtra(DisplayTextActivity.EXTRA_METADATA, result);
+ activity.startActivity(intent);
} else {