Fixed PGP import

This commit is contained in:
RainLoop Team 2015-03-26 16:46:17 +04:00
parent c4aabb0cd4
commit 470b3645e2
5 changed files with 16 additions and 4 deletions

View file

@ -41,8 +41,11 @@
oOpenpgpKeyring = PgpStore.openpgpKeyring oOpenpgpKeyring = PgpStore.openpgpKeyring
; ;
sKey = sKey.replace(/[\r\n]([a-zA-Z0-9]{2,}:[^\r\n]+)[\r\n]+([a-zA-Z0-9\/\\+=]{10,})/g, '\n$1!-!N!-!$2') if (/[\n]/.test(sKey))
.replace(/[\n\r]+/g, '\n').replace(/!-!N!-!/g, '\n\n'); {
sKey = sKey.replace(/[\r]+/g, '')
.replace(/[\n]{2,}/g, '\n\n');
}
this.key.error('' === sKey); this.key.error('' === sKey);

View file

@ -120,7 +120,7 @@ cfg.paths.js = {
openpgp: { openpgp: {
name: 'openpgp.js', name: 'openpgp.js',
src: [ src: [
'vendors/openpgp/openpgp-0.7.2.min.js' 'vendors/openpgp/openpgp-0.10.1.min.js'
] ]
}, },
encrypt: { encrypt: {

View file

@ -121,7 +121,7 @@
<span data-bind="text: uploadDataDesc"></span> <span data-bind="text: uploadDataDesc"></span>
</span> </span>
&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;
<a href="#" target="_blank" class="btn btn-small" data-bind="link: phpInfoLink()"> <a href="#" target="_blank" class="btn btn-thin" data-bind="link: phpInfoLink()">
<i class="icon-info"></i> <i class="icon-info"></i>
</a> </a>
</div> </div>

View file

@ -180,6 +180,7 @@
<div class="pull-right" style="margin-right: 4px;"> <div class="pull-right" style="margin-right: 4px;">
<div class="btn-group pull-right"> <div class="btn-group pull-right">
<a class="btn first" data-tooltip-placement="top" <a class="btn first" data-tooltip-placement="top"
style="padding-left: 10px; padding-right: 10px;"
data-bind="visible: addAttachmentEnabled(), initDom: composeUploaderButton, tooltip: 'COMPOSE/ATTACH_FILES'"> data-bind="visible: addAttachmentEnabled(), initDom: composeUploaderButton, tooltip: 'COMPOSE/ATTACH_FILES'">
<sup style="font-weight: bold; font-size: 100%; top: -0.3em;">+</sup><i class="icon-attachment"></i> <sup style="font-weight: bold; font-size: 100%; top: -0.3em;">+</sup><i class="icon-attachment"></i>
</a> </a>

8
vendors/openpgp/openpgp-0.10.1.min.js vendored Normal file

File diff suppressed because one or more lines are too long