diff options
author | Vincent Breitmoser <valodim@mugenguild.com> | 2014-07-27 01:22:10 +0200 |
---|---|---|
committer | Vincent Breitmoser <valodim@mugenguild.com> | 2014-07-27 01:22:10 +0200 |
commit | f4ee71e3ef0dcacf691def97a94880b277a99496 (patch) | |
tree | 20cf9e8252a8efab967322db9f5809b5c1a3b00f /OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java | |
parent | a8782272b3db20ba6e88acab1d035d4699aa7166 (diff) | |
download | open-keychain-f4ee71e3ef0dcacf691def97a94880b277a99496.tar.gz open-keychain-f4ee71e3ef0dcacf691def97a94880b277a99496.tar.bz2 open-keychain-f4ee71e3ef0dcacf691def97a94880b277a99496.zip |
introduce EditKeyResult with transient UncachedKeyRing (half-baked!)
Diffstat (limited to 'OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java')
-rw-r--r-- | OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java index 8fc4cffb8..5ff864547 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EditKeyFragment.java @@ -48,6 +48,7 @@ import org.sufficientlysecure.keychain.provider.ProviderHelper; import org.sufficientlysecure.keychain.service.KeychainIntentService; import org.sufficientlysecure.keychain.service.KeychainIntentServiceHandler; import org.sufficientlysecure.keychain.service.OperationResults; +import org.sufficientlysecure.keychain.service.OperationResults.EditKeyResult; import org.sufficientlysecure.keychain.service.OperationResults.ImportKeyResult; import org.sufficientlysecure.keychain.service.PassphraseCacheService; import org.sufficientlysecure.keychain.service.SaveKeyringParcel; @@ -467,21 +468,18 @@ public class EditKeyFragment extends LoaderFragment implements super.handleMessage(message); if (message.arg1 == KeychainIntentServiceHandler.MESSAGE_OKAY) { - getActivity().finish(); - // TODO below // get returned data bundle Bundle returnData = message.getData(); if (returnData == null) { return; } - final OperationResults.SaveKeyringResult result = - returnData.getParcelable(KeychainIntentService.RESULT); + final OperationResults.EditKeyResult result = + returnData.getParcelable(EditKeyResult.EXTRA_RESULT); if (result == null) { return; } - // if bad -> display here! if (!result.success()) { result.createNotify(getActivity()).show(); @@ -490,7 +488,7 @@ public class EditKeyFragment extends LoaderFragment implements // if good -> finish, return result to showkey and display there! Intent intent = new Intent(); - intent.putExtra(ImportKeyResult.EXTRA_RESULT, result); + intent.putExtra(EditKeyResult.EXTRA_RESULT, result); getActivity().setResult(EditKeyActivity.RESULT_OK, intent); getActivity().finish(); |