mirror of
https://github.com/moparisthebest/open-keychain
synced 2025-02-01 07:30:18 -05:00
rename SaveKeyringParcel to OldSaveKeyringParcel
This commit is contained in:
parent
e7fa124108
commit
ce1c3d1a1e
@ -48,7 +48,7 @@ import org.spongycastle.openpgp.operator.jcajce.JcePBESecretKeyEncryptorBuilder;
|
|||||||
import org.sufficientlysecure.keychain.Constants;
|
import org.sufficientlysecure.keychain.Constants;
|
||||||
import org.sufficientlysecure.keychain.R;
|
import org.sufficientlysecure.keychain.R;
|
||||||
import org.sufficientlysecure.keychain.pgp.exception.PgpGeneralMsgIdException;
|
import org.sufficientlysecure.keychain.pgp.exception.PgpGeneralMsgIdException;
|
||||||
import org.sufficientlysecure.keychain.service.SaveKeyringParcel;
|
import org.sufficientlysecure.keychain.service.OldSaveKeyringParcel;
|
||||||
import org.sufficientlysecure.keychain.util.Primes;
|
import org.sufficientlysecure.keychain.util.Primes;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
@ -193,7 +193,7 @@ public class PgpKeyOperation {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public UncachedKeyRing buildNewSecretKey(
|
public UncachedKeyRing buildNewSecretKey(
|
||||||
SaveKeyringParcel saveParcel)
|
OldSaveKeyringParcel saveParcel)
|
||||||
throws PgpGeneralMsgIdException, PGPException, SignatureException, IOException {
|
throws PgpGeneralMsgIdException, PGPException, SignatureException, IOException {
|
||||||
|
|
||||||
int usageId = saveParcel.keysUsages.get(0);
|
int usageId = saveParcel.keysUsages.get(0);
|
||||||
@ -338,7 +338,7 @@ public class PgpKeyOperation {
|
|||||||
|
|
||||||
public Pair<UncachedKeyRing, UncachedKeyRing> buildSecretKey(WrappedSecretKeyRing wmKR,
|
public Pair<UncachedKeyRing, UncachedKeyRing> buildSecretKey(WrappedSecretKeyRing wmKR,
|
||||||
WrappedPublicKeyRing wpKR,
|
WrappedPublicKeyRing wpKR,
|
||||||
SaveKeyringParcel saveParcel)
|
OldSaveKeyringParcel saveParcel)
|
||||||
throws PgpGeneralMsgIdException, PGPException, SignatureException, IOException {
|
throws PgpGeneralMsgIdException, PGPException, SignatureException, IOException {
|
||||||
|
|
||||||
PGPSecretKeyRing mKR = wmKR.getRing();
|
PGPSecretKeyRing mKR = wmKR.getRing();
|
||||||
|
@ -497,7 +497,7 @@ public class KeychainIntentService extends IntentService
|
|||||||
} else if (ACTION_SAVE_KEYRING.equals(action)) {
|
} else if (ACTION_SAVE_KEYRING.equals(action)) {
|
||||||
try {
|
try {
|
||||||
/* Input */
|
/* Input */
|
||||||
SaveKeyringParcel saveParcel = data.getParcelable(SAVE_KEYRING_PARCEL);
|
OldSaveKeyringParcel saveParcel = data.getParcelable(SAVE_KEYRING_PARCEL);
|
||||||
String oldPassphrase = saveParcel.oldPassphrase;
|
String oldPassphrase = saveParcel.oldPassphrase;
|
||||||
String newPassphrase = saveParcel.newPassphrase;
|
String newPassphrase = saveParcel.newPassphrase;
|
||||||
boolean canSign = true;
|
boolean canSign = true;
|
||||||
|
@ -31,7 +31,12 @@ import java.io.IOException;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
|
|
||||||
public class SaveKeyringParcel implements Parcelable {
|
/** Class for parcelling data between ui and services.
|
||||||
|
* This class is outdated and scheduled for removal, pending a rewrite of the
|
||||||
|
* EditKeyActivity and save keyring routines.
|
||||||
|
*/
|
||||||
|
@Deprecated
|
||||||
|
public class OldSaveKeyringParcel implements Parcelable {
|
||||||
|
|
||||||
public ArrayList<String> userIds;
|
public ArrayList<String> userIds;
|
||||||
public ArrayList<String> originalIDs;
|
public ArrayList<String> originalIDs;
|
||||||
@ -48,9 +53,9 @@ public class SaveKeyringParcel implements Parcelable {
|
|||||||
public ArrayList<UncachedSecretKey> keys;
|
public ArrayList<UncachedSecretKey> keys;
|
||||||
public String originalPrimaryID;
|
public String originalPrimaryID;
|
||||||
|
|
||||||
public SaveKeyringParcel() {}
|
public OldSaveKeyringParcel() {}
|
||||||
|
|
||||||
private SaveKeyringParcel(Parcel source) {
|
private OldSaveKeyringParcel(Parcel source) {
|
||||||
userIds = (ArrayList<String>) source.readSerializable();
|
userIds = (ArrayList<String>) source.readSerializable();
|
||||||
originalIDs = (ArrayList<String>) source.readSerializable();
|
originalIDs = (ArrayList<String>) source.readSerializable();
|
||||||
deletedIDs = (ArrayList<String>) source.readSerializable();
|
deletedIDs = (ArrayList<String>) source.readSerializable();
|
||||||
@ -90,13 +95,13 @@ public class SaveKeyringParcel implements Parcelable {
|
|||||||
destination.writeString(originalPrimaryID);
|
destination.writeString(originalPrimaryID);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static final Creator<SaveKeyringParcel> CREATOR = new Creator<SaveKeyringParcel>() {
|
public static final Creator<OldSaveKeyringParcel> CREATOR = new Creator<OldSaveKeyringParcel>() {
|
||||||
public SaveKeyringParcel createFromParcel(final Parcel source) {
|
public OldSaveKeyringParcel createFromParcel(final Parcel source) {
|
||||||
return new SaveKeyringParcel(source);
|
return new OldSaveKeyringParcel(source);
|
||||||
}
|
}
|
||||||
|
|
||||||
public SaveKeyringParcel[] newArray(final int size) {
|
public OldSaveKeyringParcel[] newArray(final int size) {
|
||||||
return new SaveKeyringParcel[size];
|
return new OldSaveKeyringParcel[size];
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
@ -57,8 +57,8 @@ import org.sufficientlysecure.keychain.provider.KeychainContract.KeyRings;
|
|||||||
import org.sufficientlysecure.keychain.provider.ProviderHelper;
|
import org.sufficientlysecure.keychain.provider.ProviderHelper;
|
||||||
import org.sufficientlysecure.keychain.service.KeychainIntentService;
|
import org.sufficientlysecure.keychain.service.KeychainIntentService;
|
||||||
import org.sufficientlysecure.keychain.service.KeychainIntentServiceHandler;
|
import org.sufficientlysecure.keychain.service.KeychainIntentServiceHandler;
|
||||||
|
import org.sufficientlysecure.keychain.service.OldSaveKeyringParcel;
|
||||||
import org.sufficientlysecure.keychain.service.PassphraseCacheService;
|
import org.sufficientlysecure.keychain.service.PassphraseCacheService;
|
||||||
import org.sufficientlysecure.keychain.service.SaveKeyringParcel;
|
|
||||||
import org.sufficientlysecure.keychain.ui.dialog.CustomAlertDialogBuilder;
|
import org.sufficientlysecure.keychain.ui.dialog.CustomAlertDialogBuilder;
|
||||||
import org.sufficientlysecure.keychain.ui.dialog.PassphraseDialogFragment;
|
import org.sufficientlysecure.keychain.ui.dialog.PassphraseDialogFragment;
|
||||||
import org.sufficientlysecure.keychain.ui.dialog.SetPassphraseDialogFragment;
|
import org.sufficientlysecure.keychain.ui.dialog.SetPassphraseDialogFragment;
|
||||||
@ -553,7 +553,7 @@ public class EditKeyActivity extends ActionBarActivity implements EditorListener
|
|||||||
|
|
||||||
intent.setAction(KeychainIntentService.ACTION_SAVE_KEYRING);
|
intent.setAction(KeychainIntentService.ACTION_SAVE_KEYRING);
|
||||||
|
|
||||||
SaveKeyringParcel saveParams = new SaveKeyringParcel();
|
OldSaveKeyringParcel saveParams = new OldSaveKeyringParcel();
|
||||||
saveParams.userIds = getUserIds(mUserIdsView);
|
saveParams.userIds = getUserIds(mUserIdsView);
|
||||||
saveParams.originalIDs = mUserIdsView.getOriginalIDs();
|
saveParams.originalIDs = mUserIdsView.getOriginalIDs();
|
||||||
saveParams.deletedIDs = mUserIdsView.getDeletedIDs();
|
saveParams.deletedIDs = mUserIdsView.getDeletedIDs();
|
||||||
|
Loading…
Reference in New Issue
Block a user