128d5bb3ea
Monotone-Revision: 5aaf09a46fc504e57187524d01cb8ccb8d9c8e1e Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2008-08-15T01:48:07 Monotone-Branch: ca.inverse.sogo
45 lines
1.1 KiB
JavaScript
45 lines
1.1 KiB
JavaScript
function onPrintCurrentMessage(event) {
|
|
window.print();
|
|
|
|
preventDefault(event);
|
|
}
|
|
|
|
function initPopupMailer(event) {
|
|
configureLinksInMessage();
|
|
resizeMailContent();
|
|
}
|
|
|
|
function onICalendarButtonClick(event) {
|
|
var link = $("iCalendarAttachment").value;
|
|
if (link) {
|
|
var urlstr = link + "/" + this.action;
|
|
var currentMsg;
|
|
if (window.opener && window.opener.open && !window.opener.closed && window.messageUID) {
|
|
var c = window.opener;
|
|
window.opener.triggerAjaxRequest(urlstr,
|
|
window.opener.ICalendarButtonCallback,
|
|
window.messageUID);
|
|
}
|
|
}
|
|
else
|
|
log("no link");
|
|
}
|
|
|
|
function onMenuDeleteMessage(event) {
|
|
if (window.opener && window.opener.open && !window.opener.closed) {
|
|
var rowId = window.name.substr(9);
|
|
var messageId = window.opener.Mailer.currentMailbox + "/" + rowId;
|
|
var url = ApplicationBaseURL + messageId + "/trash";
|
|
|
|
window.opener.deleteMessageWithDelay(url,
|
|
rowId,
|
|
window.opener.Mailer.currentMailbox,
|
|
messageId);
|
|
}
|
|
|
|
window.close();
|
|
return false;
|
|
}
|
|
|
|
FastInit.addOnLoad(initPopupMailer);
|