mirror of
https://github.com/moparisthebest/open-keychain
synced 2024-11-23 17:22:16 -05:00
Fixes for share to decrypt
This commit is contained in:
parent
8e5c5c9503
commit
43140c10b1
@ -112,11 +112,11 @@ public class DecryptTextActivity extends ActionBarActivity {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (Intent.ACTION_SEND.equals(action) && type != null) {
|
if (Intent.ACTION_SEND.equals(action) && type != null) {
|
||||||
// Android action
|
Log.logDebugBundle(extras, "extras");
|
||||||
|
|
||||||
// When sending to Keychain Decrypt via share menu
|
// When sending to Keychain Decrypt via share menu
|
||||||
if ("text/plain".equals(type)) {
|
if ("text/plain".equals(type)) {
|
||||||
String sharedText = intent.getStringExtra(Intent.EXTRA_TEXT);
|
String sharedText = extras.getString(Intent.EXTRA_TEXT);
|
||||||
sharedText = getPgpContent(sharedText);
|
sharedText = getPgpContent(sharedText);
|
||||||
|
|
||||||
if (sharedText != null) {
|
if (sharedText != null) {
|
||||||
|
@ -302,7 +302,6 @@ public class EncryptTextActivity extends EncryptActivity implements EncryptActiv
|
|||||||
// Handle intent actions
|
// Handle intent actions
|
||||||
handleActions(getIntent());
|
handleActions(getIntent());
|
||||||
updateModeFragment();
|
updateModeFragment();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -359,9 +358,11 @@ public class EncryptTextActivity extends EncryptActivity implements EncryptActiv
|
|||||||
|
|
||||||
// When sending to OpenKeychain Encrypt via share menu
|
// When sending to OpenKeychain Encrypt via share menu
|
||||||
if (Intent.ACTION_SEND.equals(action) && type != null) {
|
if (Intent.ACTION_SEND.equals(action) && type != null) {
|
||||||
|
Log.logDebugBundle(extras, "extras");
|
||||||
|
|
||||||
// When sending to OpenKeychain Encrypt via share menu
|
// When sending to OpenKeychain Encrypt via share menu
|
||||||
if ("text/plain".equals(type)) {
|
if ("text/plain".equals(type)) {
|
||||||
String sharedText = intent.getStringExtra(Intent.EXTRA_TEXT);
|
String sharedText = extras.getString(Intent.EXTRA_TEXT);
|
||||||
if (sharedText != null) {
|
if (sharedText != null) {
|
||||||
// handle like normal text encryption, override action and extras to later
|
// handle like normal text encryption, override action and extras to later
|
||||||
// executeServiceMethod ACTION_ENCRYPT_TEXT in main actions
|
// executeServiceMethod ACTION_ENCRYPT_TEXT in main actions
|
||||||
|
Loading…
Reference in New Issue
Block a user