mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-01 05:29:20 +03:00
Many more changes for #89
This commit is contained in:
parent
3cc3a76b23
commit
a7eeeb4f55
18 changed files with 310 additions and 236 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import { pInt } from 'Common/Utils';
|
||||
|
||||
import { PgpUserStore } from 'Stores/User/Pgp';
|
||||
import { IdentityUserStore } from 'Stores/User/Identity';
|
||||
|
||||
import { decorateKoCommands } from 'Knoin/Knoin';
|
||||
import { AbstractViewPopup } from 'Knoin/AbstractViews';
|
||||
|
|
@ -9,6 +10,8 @@ class NewOpenPgpKeyPopupView extends AbstractViewPopup {
|
|||
constructor() {
|
||||
super('NewOpenPgpKey');
|
||||
|
||||
this.identities = IdentityUserStore;
|
||||
|
||||
this.addObservables({
|
||||
email: '',
|
||||
emailError: false,
|
||||
|
|
@ -63,6 +66,9 @@ class NewOpenPgpKeyPopupView extends AbstractViewPopup {
|
|||
openpgpKeyring.store();
|
||||
|
||||
PgpUserStore.reloadOpenPgpKeys();
|
||||
|
||||
PgpUserStore.gnupgImportKey(keyPair.privateKeyArmored);
|
||||
|
||||
this.cancelCommand();
|
||||
}
|
||||
})
|
||||
|
|
@ -87,13 +93,11 @@ class NewOpenPgpKeyPopupView extends AbstractViewPopup {
|
|||
}
|
||||
|
||||
onShow() {
|
||||
this.name('');
|
||||
this.name(IdentityUserStore()[0].name());
|
||||
this.password('');
|
||||
|
||||
this.email('');
|
||||
this.email(IdentityUserStore()[0].email());
|
||||
this.emailError(false);
|
||||
this.keyBitLength(4096);
|
||||
|
||||
this.submitError('');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue