Fix QR Code URI

This commit is contained in:
Dominik Schürmann 2014-02-01 22:06:57 +01:00
parent 4e32459824
commit 20af0d3b2e
2 changed files with 4 additions and 7 deletions

View File

@ -417,7 +417,7 @@ public class ViewKeyActivity extends SherlockFragmentActivity implements
byte[] fingerprintBlob = ProviderHelper.getFingerprint(this, dataUri);
String fingerprint = PgpKeyHelper.convertFingerprintToHex(fingerprintBlob, false);
content = Constants.FINGERPRINT_SCHEME + fingerprint;
content = Constants.FINGERPRINT_SCHEME + ":" + fingerprint;
} else {
// get public keyring as ascii armored string
long masterKeyId = ProviderHelper.getMasterKeyId(this, dataUri);

View File

@ -90,16 +90,14 @@ public class ShareQrCodeDialogFragment extends SherlockDialogFragment {
String content = null;
if (mFingerprintOnly) {
alert.setPositiveButton(R.string.btn_okay, null);
byte[] fingerprintBlob = ProviderHelper.getFingerprint(getActivity(), dataUri);
String fingerprint = PgpKeyHelper.convertFingerprintToHex(fingerprintBlob, false);
mText.setText(getString(R.string.share_qr_code_dialog_fingerprint_text) + " " + fingerprint);
content = Constants.FINGERPRINT_SCHEME + fingerprint;
Log.d(Constants.TAG, "content: " + content);
alert.setPositiveButton(R.string.btn_okay, null);
content = Constants.FINGERPRINT_SCHEME + ":" + fingerprint;
setQrCode(content);
} else {
mText.setText(R.string.share_qr_code_dialog_start);
@ -107,7 +105,6 @@ public class ShareQrCodeDialogFragment extends SherlockDialogFragment {
// TODO
long masterKeyId = ProviderHelper.getMasterKeyId(getActivity(), dataUri);
// get public keyring as ascii armored string
ArrayList<String> keyringArmored = ProviderHelper.getKeyRingsAsArmoredString(
getActivity(), dataUri, new long[]{masterKeyId});