mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-11 00:14:50 +03:00
mailto link parser
This commit is contained in:
parent
6ad84283b7
commit
016b3eead3
8 changed files with 146 additions and 30 deletions
|
|
@ -355,9 +355,9 @@ MailBoxMessageViewViewModel.prototype.onBuild = function (oDom)
|
|||
self.message.focused(true);
|
||||
}
|
||||
})
|
||||
.on('mousedown', 'a', function (oEvent) {
|
||||
.on('click', 'a', function (oEvent) {
|
||||
// setup maito protocol
|
||||
return !(oEvent && 3 !== oEvent['which'] && RL.mailToHelper($(this).attr('href')));
|
||||
return !(!!oEvent && 3 !== oEvent['which'] && RL.mailToHelper($(this).attr('href')));
|
||||
})
|
||||
.on('click', '.attachmentsPlace .attachmentPreview', function (oEvent) {
|
||||
if (oEvent && oEvent.stopPropagation)
|
||||
|
|
|
|||
|
|
@ -655,8 +655,10 @@ PopupsComposeViewModel.prototype.editor = function (fOnInit)
|
|||
* @param {string=} sType = Enums.ComposeType.Empty
|
||||
* @param {?MessageModel|Array=} oMessageOrArray = null
|
||||
* @param {Array=} aToEmails = null
|
||||
* @param {string=} sCustomSubject = null
|
||||
* @param {string=} sCustomPlainText = null
|
||||
*/
|
||||
PopupsComposeViewModel.prototype.onShow = function (sType, oMessageOrArray, aToEmails)
|
||||
PopupsComposeViewModel.prototype.onShow = function (sType, oMessageOrArray, aToEmails, sCustomSubject, sCustomPlainText)
|
||||
{
|
||||
kn.routeOff();
|
||||
|
||||
|
|
@ -850,7 +852,14 @@ PopupsComposeViewModel.prototype.onShow = function (sType, oMessageOrArray, aToE
|
|||
}
|
||||
else if (Enums.ComposeType.Empty === sComposeType)
|
||||
{
|
||||
sText = this.convertSignature(sSignature);
|
||||
this.subject(Utils.isNormal(sCustomSubject) ? '' + sCustomSubject : '');
|
||||
|
||||
sText = Utils.isNormal(sCustomPlainText) ? '' + sCustomPlainText : '';
|
||||
if (bSignatureToAll && '' !== sSignature && '' !== sText)
|
||||
{
|
||||
sText = this.convertSignature(sSignature) + '<br />' + sText;
|
||||
}
|
||||
|
||||
this.editor(function (oEditor) {
|
||||
oEditor.setHtml(sText, false);
|
||||
if (Enums.EditorDefaultType.Html !== RL.data().editorDefaultType())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue