2008-07-22 16:21:15 +04:00
|
|
|
<?xml version="1.0"?>
|
2012-05-30 20:48:24 +04:00
|
|
|
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
|
|
|
|
2008-07-22 16:21:15 +04:00
|
|
|
|
|
|
|
<!-- retrieve generic commands -->
|
|
|
|
<?xul-overlay href="chrome://messenger/content/mailOverlay.xul"?>
|
|
|
|
|
|
|
|
<!DOCTYPE overlay SYSTEM "chrome://messenger/locale/mailEditorOverlay.dtd" >
|
|
|
|
|
|
|
|
<overlay id="mailEditorOverlay"
|
|
|
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
|
|
|
|
2009-10-09 01:29:19 +04:00
|
|
|
<script type="application/javascript">
|
2008-07-22 16:21:15 +04:00
|
|
|
<![CDATA[
|
|
|
|
|
|
|
|
function openComposeWindow(pageUrl, pageTitle)
|
|
|
|
{
|
|
|
|
var params = Components.classes["@mozilla.org/messengercompose/composeparams;1"].createInstance(Components.interfaces.nsIMsgComposeParams);
|
|
|
|
if (params)
|
|
|
|
{
|
|
|
|
params.composeFields = Components.classes['@mozilla.org/messengercompose/composefields;1'].createInstance(Components.interfaces.nsIMsgCompFields);
|
|
|
|
if (params.composeFields)
|
|
|
|
{
|
|
|
|
params.composeFields.body = pageUrl;
|
|
|
|
params.composeFields.subject = pageTitle;
|
|
|
|
var attachmentData = Components.classes["@mozilla.org/messengercompose/attachment;1"].createInstance(Components.interfaces.nsIMsgAttachment);
|
|
|
|
if (attachmentData)
|
|
|
|
{
|
|
|
|
attachmentData.url = pageUrl;
|
|
|
|
params.composeFields.addAttachment(attachmentData);
|
|
|
|
}
|
|
|
|
params.bodyIsLink = true;
|
|
|
|
|
|
|
|
var composeService = Components.classes["@mozilla.org/messengercompose;1"].getService(Components.interfaces.nsIMsgComposeService);
|
|
|
|
if (composeService)
|
|
|
|
composeService.OpenComposeWindowWithParams(null, params);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
]]>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<!-- editor specific UI items -->
|
|
|
|
<menupopup id="menu_NewPopup">
|
|
|
|
<!-- Command nodes and implemention are in mailOverlay.xul -->
|
|
|
|
<menuitem id="menu_newMessage" insertafter="menu_newNavigator"/>
|
|
|
|
<menuitem id="menu_newCard" insertafter="menu_newNavigator"/>
|
|
|
|
</menupopup>
|
|
|
|
|
|
|
|
<menupopup id="menu_FilePopup">
|
2011-04-20 03:33:28 +04:00
|
|
|
<!-- The command node cmd_editSendPage is in editor.xul.
|
2008-07-22 16:21:15 +04:00
|
|
|
Implementation is in ComposerCommands.js
|
|
|
|
-->
|
|
|
|
<menuitem id="menu_sendPage" label="&sendPage.label;" accesskey="&sendPage.accesskey;" observes="cmd_editSendPage" insertafter="previewInBrowser"/>
|
|
|
|
</menupopup>
|
|
|
|
|
|
|
|
</overlay>
|
|
|
|
|