[Phoenix-commits] rev 13306 - in public/phoenix:
deliverables/design trunk/phoenix trunk/phoenix/demo
trunk/phoenix/demo/chrome trunk/phoenix/demo/chrome/content
trunk/phoenix/demo/chrome/locale
andi at wyona.com
andi at wyona.com
Mon May 15 15:03:09 CEST 2006
Author: andi
Date: 2006-05-15 15:03:05 +0200 (Mon, 15 May 2006)
New Revision: 13306
Added:
public/phoenix/trunk/phoenix/demo/
public/phoenix/trunk/phoenix/demo/chrome.manifest
public/phoenix/trunk/phoenix/demo/chrome/
public/phoenix/trunk/phoenix/demo/chrome/content/
public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.js
public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.xul
public/phoenix/trunk/phoenix/demo/chrome/locale/
public/phoenix/trunk/phoenix/demo/chrome/locale/en/
public/phoenix/trunk/phoenix/demo/chrome/skin/
public/phoenix/trunk/phoenix/demo/install.rdf
Modified:
public/phoenix/deliverables/design/code_design_overall.db
public/phoenix/deliverables/design/code_design_overall.xhtml
public/phoenix/deliverables/design/code_design_overall.xml
Log:
Added demo skeleton.
Modified: public/phoenix/deliverables/design/code_design_overall.db
===================================================================
--- public/phoenix/deliverables/design/code_design_overall.db 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/deliverables/design/code_design_overall.db 2006-05-15 13:03:05 UTC (rev 13306)
@@ -2,7 +2,23 @@
<ttl>Phoenix General Code Design</ttl>
<xreftext>Phoenix General Code Design</xreftext>
<div element="section" href="code_design_overall.xhtml#id342752" number="1">
- <ttl>Overview</ttl>
- <xreftext>Section 1, “Overview”</xreftext>
+ <ttl>Basic Processing Loop</ttl>
+ <xreftext>Section 1, “Basic Processing Loop”</xreftext>
+ <div element="section" href="code_design_overall.xhtml#id342758" number="1.1">
+ <ttl>Standard Variant</ttl>
+ <xreftext>Section 1.1, “Standard Variant”</xreftext>
+ <obj element="figure" href="code_design_overall.xhtml#id342767" number="1">
+ <ttl>Basic Processing Loop (Standard Variant)</ttl>
+ <xreftext>Figure 1, “Basic Processing Loop (Standard Variant)”</xreftext>
+ </obj>
+ </div>
+ <div element="section" href="code_design_overall.xhtml#id342794" number="1.2">
+ <ttl>More than XML Variant</ttl>
+ <xreftext>Section 1.2, “More than XML Variant”</xreftext>
+ <obj element="figure" href="code_design_overall.xhtml#id342800" number="2">
+ <ttl>Basic Processing Loop (More than XML Variant)</ttl>
+ <xreftext>Figure 2, “Basic Processing Loop (More than XML Variant)”</xreftext>
+ </obj>
+ </div>
</div>
</div>
Modified: public/phoenix/deliverables/design/code_design_overall.xhtml
===================================================================
--- public/phoenix/deliverables/design/code_design_overall.xhtml 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/deliverables/design/code_design_overall.xhtml 2006-05-15 13:03:05 UTC (rev 13306)
@@ -25,7 +25,7 @@
</div>
</div>
<div>
- <p class="pubdate">2006-05-07</p>
+ <p class="pubdate">2006-05-14</p>
</div>
<div>
<div class="revhistory">
@@ -37,7 +37,7 @@
</tr>
<tr>
<td align="left">Revision 1.0</td>
- <td align="left">2006-05-07</td>
+ <td align="left">2006-05-14</td>
<td align="left">AW</td>
</tr>
<tr>
@@ -64,22 +64,69 @@
<dl>
<dt>
<span class="section">
- <a href="#id342753">1. Overview</a>
+ <a href="#id342753">1. Basic Processing Loop</a>
</span>
</dt>
+ <dd>
+ <dl>
+ <dt>
+ <span class="section">
+ <a href="#id342758">1.1. Standard Variant</a>
+ </span>
+ </dt>
+ <dt>
+ <span class="section">
+ <a href="#id342795">1.2. More than XML Variant</a>
+ </span>
+ </dt>
+ </dl>
+ </dd>
</dl>
</div>
<div class="section" lang="en">
<div class="titlepage">
<div>
<div>
- <h2 class="title"><a id="id342753"/>1. Overview</h2>
+ <h2 class="title"><a id="id342753"/>1. Basic Processing Loop</h2>
</div>
</div>
</div>
- <p>
-
- </p>
+ <div class="section" lang="en">
+ <div class="titlepage">
+ <div>
+ <div>
+ <h3 class="title"><a id="id342758"/>1.1. Standard Variant</h3>
+ </div>
+ </div>
+ </div>
+ <div class="figure">
+ <a id="id342767"/>
+ <p class="title">
+ <b>Figure 1. Basic Processing Loop (Standard Variant)</b>
+ </p>
+ <div class="mediaobject">
+ <img src="figures/basic_processing_loop.png" alt="Basic Processing Loop (Standard Variant)"/>
+ </div>
+ </div>
+ </div>
+ <div class="section" lang="en">
+ <div class="titlepage">
+ <div>
+ <div>
+ <h3 class="title"><a id="id342795"/>1.2. More than XML Variant</h3>
+ </div>
+ </div>
+ </div>
+ <div class="figure">
+ <a id="id342800"/>
+ <p class="title">
+ <b>Figure 2. Basic Processing Loop (More than XML Variant)</b>
+ </p>
+ <div class="mediaobject">
+ <img src="figures/basic_processing_loop-mtxml_uc1+2.png" alt="Basic Processing Loop (More than XML Variant)"/>
+ </div>
+ </div>
+ </div>
</div>
</div>
</body>
Modified: public/phoenix/deliverables/design/code_design_overall.xml
===================================================================
--- public/phoenix/deliverables/design/code_design_overall.xml 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/deliverables/design/code_design_overall.xml 2006-05-15 13:03:05 UTC (rev 13306)
@@ -22,12 +22,12 @@
</author>
</authorgroup>
<!-- All dates specified in ISO "YYYY-MM-DD" format -->
- <pubdate>2006-05-07</pubdate>
+ <pubdate>2006-05-14</pubdate>
<!-- Most recent revision goes at the top; list in descending order -->
<revhistory>
<revision>
<revnumber>1.0</revnumber>
- <date>2006-05-07</date>
+ <date>2006-05-14</date>
<authorinitials>AW</authorinitials>
<revremark>First initial draft.</revremark>
</revision>
@@ -38,10 +38,36 @@
</articleinfo>
<section>
- <title>Overview</title>
- <para>
+ <title>Basic Processing Loop</title>
+ <section>
+ <title>Standard Variant</title>
+ <figure>
+ <title>Basic Processing Loop (Standard Variant)</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="figures/basic_processing_loop.png" format="PNG" scale="100"/>
+ </imageobject>
+ <textobject>
+ <phrase>Basic Processing Loop (Standard Variant)</phrase>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </section>
- </para>
+ <section>
+ <title>More than XML Variant</title>
+ <figure>
+ <title>Basic Processing Loop (More than XML Variant)</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="figures/basic_processing_loop-mtxml_uc1+2.png" format="PNG" scale="100"/>
+ </imageobject>
+ <textobject>
+ <phrase>Basic Processing Loop (More than XML Variant)</phrase>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </section>
</section>
</article>
Added: public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.js
===================================================================
--- public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.js 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.js 2006-05-15 13:03:05 UTC (rev 13306)
@@ -0,0 +1,403 @@
+/*
+ * ***** BEGIN LICENSE BLOCK *****
+ * Copyright 2006 Wyona AG Zurich
+ *
+ * This file is part of CMSConnector.
+ *
+ * CMSConnector is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * CMSConnector is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with CMSConnector; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * ***** END LICENSE BLOCK *****
+ */
+
+/**
+ * @author Andreas Wuest
+ *
+ * This module contains the glue code to dispatch the upload actions.
+ * <p>
+ * The code in this module serves to separate the internal Mozilla
+ * mail implementation from the rest of the CMSConnector code to
+ * render it implementation indepedendent.
+ */
+
+const XMOZ_DELETED_MIME_TYPE = "text/x-moz-deleted"
+const XUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
+
+var menuAlreadySetup = false;
+
+/* Registers our init code to be run (see
+ * http://developer.mozilla.org/en/docs/Extension_FAQ#Why_doesn.27t_my_script_run_properly.3F) */
+window.addEventListener('load', initCMSConnector, false);
+
+/**
+ * Event handler for setting up CMSConnector for active message instance.
+ *
+ * @return {Undefined}
+ */
+function initCMSConnector() {
+ // /* DEBUG */ dump("CMSConnector:cmsconnector.js:initCMSConnector() invoked\n");
+
+ document.getElementById('attachmentListContext').addEventListener('popupshowing', attachmentListContextOnPopupShowingListener, false);
+ document.getElementById('attachmentMenuList').addEventListener('popupshowing', attachmentMenuListOnPopupShowingListener, false);
+}
+
+/**
+ * Event handler for updating the context menu
+ * depending on the state of the selected attachments.
+ * <p>
+ * Note that this handler is called iff the message has
+ * at least one attachment associated.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal property
+ * document.getElementById('attachmentList').selectedItems[].attachment.
+ *
+ * @return {Undefined}
+ */
+function attachmentListContextOnPopupShowingListener() {
+ // /* DEBUG */ dump("CMSConnector:cmsconnector.js:attachmentListContextOnPopupShowingListener() invoked\n");
+
+ var uploadMenuitem = document.getElementById('context-uploadAttachmentToCMS');
+ var uploadAllMenuitem = document.getElementById('context-uploadAllAttachmentsToCMS');
+ var attachmentList = document.getElementById('attachmentList');
+
+ uploadMenuitem.setAttribute('disabled', 'true');
+ uploadAllMenuitem.setAttribute('disabled', 'true');
+
+ /* Check if there are any attachments selected at all, and if
+ * yes, check if there is at least one attachment in the selection
+ * which is eligible for upload (i.e. not marked as deleted). */
+ for (var i = 0; i < attachmentList.selectedItems.length; i++) {
+ if (attachmentList.selectedItems[i].attachment.contentType != XMOZ_DELETED_MIME_TYPE) {
+ uploadMenuitem.removeAttribute('disabled');
+ break;
+ }
+ }
+
+ if (existsEligibleAttachment())
+ uploadAllMenuitem.removeAttribute('disabled');
+}
+
+/**
+ * Event handler for updating the File -> Attachments menu
+ * depending on the state of the selected attachments.
+ * <p>
+ * Note that this handler is called iff the message has
+ * at least one attachment associated.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of calling the internal function
+ * cloneAttachment().
+ *
+ * @return {Undefined}
+ */
+function attachmentMenuListOnPopupShowingListener() {
+ /* DEBUG */ dump("CMSConnector:cmsconnector.js:attachmentMenuListOnPopupShowingListener() invoked\n");
+
+ var attachmentMenulist = null;
+ var uploadAllMenuitem = null;
+ var domTreeWalker = null;
+ var domElem = null;
+ var menuElem = null;
+ var menupopupElem = null;
+ var prevDOMElem = null;
+ var newMenuitem = null;
+ var menusepCounter;
+
+ if (!menuAlreadySetup) {
+ // get File --> Attachments sub menu (id "attachmentMenuList")
+ attachmentMenulist = document.getElementById('attachmentMenuList');
+
+ /* The code in the following try ... catch block is quite delicate
+ * because the File --> Attachments sub menu is generated dynamically
+ * by mail/mailnews. I.e., there are no id attributes available which
+ * we could use to find our way around the tree. Furthermore, some
+ * important data like the attachment itself is only available
+ * indirectly. If some other extension hooks itself in in this menu
+ * as well, we might not be able to get the correct data out of it.
+ * Therefore, we better play save, and if anything should fail, we
+ * simply refrain from adding the "Save to CMS..." menu item. */
+ try {
+ /* Iterate over all attachment menu items in the attachments sub
+ * menu of the File -> Attachments menu. The menu looks like this:
+ * _________________________
+ * | File -> |
+ * | Open Saved Message |______________________________
+ * | Attachments -> 1 foo -> Open |
+ * | Close | 2 bar -> | ----------- |
+ * | --------------------- | ------------- | Save As... |
+ * | Save As -> | Save All... | ----------- |
+ * | ... | Detach All... | Detach... |
+ * | ... | Delete All... | Delete |
+ * | ... |---------------|-------------|
+ *
+ * The "Upload to CMS..." menu item has to get added to the
+ * sub menu of "1 foo" and "2 bar". These menus though
+ * are created dynamically, and do not have an id to hook
+ * in. */
+
+ /* Iterate over the menu items starting from the first entry, until
+ * we hit the first separator. */
+ domTreeWalker = document.createTreeWalker(attachmentMenulist, NodeFilter.SHOW_ELEMENT, null, false);
+
+ domElem = domTreeWalker.currentNode;
+
+ for (domElem = domTreeWalker.firstChild(); domElem != null && domElem.nodeName != 'menuseparator'; domElem = domTreeWalker.nextSibling()) {
+ /* Save current menu node to later proceed walking
+ * from this point in the treee. */
+ menuElem = domElem;
+
+ // goto child of the menu element which is the menupopup
+ menupopupElem = domTreeWalker.firstChild();
+
+ /* Iterate over the menupopup children until we hit the
+ * second menuseparator (i.e. the first element after the
+ * "Save As..." menuitem. */
+ for (domElem = domTreeWalker.firstChild(), prevDOMElem = null, menusepCounter = 0; domElem != null; domElem = domTreeWalker.nextSibling()) {
+ if ((domElem.nodeName == 'menuseparator' ? ++menusepCounter : menusepCounter) == 2) {
+ /* Check if previous menu item carries the attachment. If
+ * not, either something went wrong in mail/mailnews during
+ * menu creation, or some other extension hooked in in the
+ * same menu and interferes with us. In this case, we just
+ * gracefully back off. */
+ if (prevDOMElem && prevDOMElem.attachment) {
+ // build new "Upload to CMS..." menuitem
+ newMenuitem = document.getElementById('context-uploadAttachmentToCMS').cloneNode(true);
+ newMenuitem.removeAttribute('id');
+ newMenuitem.removeAttribute('insertafter');
+
+ // determine elegibility for upload
+ if (prevDOMElem.attachment.contentType != 'text/x-moz-deleted') {
+ newMenuitem.attachment = cloneAttachment(prevDOMElem.attachment);
+ newMenuitem.setAttribute('oncommand', 'uploadAttachmentToCMS(this.attachment)');
+ newMenuitem.setAttribute('disabled', false);
+ }
+
+ // insert newly built menuitem before the second menuseparator
+ menupopupElem.insertBefore(newMenuitem, domElem);
+ }
+ break;
+ }
+ prevDOMElem = domElem;
+ }
+ domTreeWalker.currentNode = menuElem;
+ }
+ } catch (exception) {
+ dump("CMSConnector:cmsconnector.js:attachmentMenuListOnPopupShowingListener: " + exception.toString() + "\n");
+ }
+
+ uploadAllMenuitem = document.getElementById('file-uploadAllAttachmentsToCMS');
+
+ uploadAllMenuitem.setAttribute('disabled', 'true');
+
+ if (existsEligibleAttachment())
+ uploadAllMenuitem.removeAttribute('disabled');
+
+ menuAlreadySetup = true;
+ }
+}
+
+/**
+ * Test if at least one attachment is eligible for upload.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal global
+ * object property currentAttachments.
+ * <p>
+ * currentAttachments is defined in
+ * chrome://messenger/content/msgHdrViewOverlay.js.
+ *
+ * @return {Boolean} returns true if at least one eligible attachment exists
+ */
+function existsEligibleAttachment() {
+ /* Check if there is at least one attachment at all (i.e. not only
+ * among the selection), which is eligible for upload (i.e. not marked
+ * as deleted). */
+ for (var i = 0; i < currentAttachments.length; i++) {
+ if (currentAttachments[i].contentType != "text/x-moz-deleted")
+ return true;
+ }
+ return false;
+}
+
+/**
+ * Called by the "Upload to CMS..." entry in the attachment
+ * context menu. Uploads all selected attachments of a given
+ * message while sequentially asking for the target node for every
+ * attachment.
+ * <p>
+ * Note that the aAttachment parameter is optional. If provided, this
+ * attachment will be uploaded. If omitted, the current selection
+ * is upload.
+ * <p>
+ * Note that there must at least one attachment be selected which
+ * is not marked as deleted.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal property
+ * document.getElementById('attachmentList').selectedItems[].attachment.
+ *
+ * @param {Object} the attachment to upload (if omitted, retrieve from selection)
+ * @return {Undefined}
+ */
+function uploadAttachmentToCMS(aAttachment) {
+ var liveAttachments = new Array();
+ var attachmentList = null;
+
+ if (!aAttachment) {
+ // get selected attachments
+ attachmentList = document.getElementById('attachmentList');
+
+
+ // filter out deleted attachments
+ for (var i = 0; i < attachmentList.selectedItems.length; i++)
+ __filterDeletedAttachments(liveAttachments, attachmentList.selectedItems[i].attachment);
+ } else {
+ // add attachment which was passed in.
+ liveAttachments.push(__createAttachment(aAttachment));
+ }
+
+ // check if there are any live attachments left to process
+ if (liveAttachments.length != 0) {
+ // maybe we need the same hack as in http://lxr.mozilla.org/mozilla/source/mail/base/content/msgHdrViewOverlay.js#1115
+ for (var i = 0; i < liveAttachments.length; i++) {
+ try {
+ __uploadAttachment(NodeSelector.selectNode(), liveAttachments[i]);
+ } catch (exception) {
+ if (exception instanceof CMSConnectorAbortException) {
+ /* DEBUG */ dump("CMSConnector:cmsconnector.js:uploadAttachmentToCMS: " + exception.toString() + "\n");
+ return;
+ } else {
+ // not a normal abruption
+ dump("CMSConnector:cmsconnector.js:uploadAttachmentToCMS: " + exception.toString() + "\n");
+ return;
+ }
+ }
+ }
+ } else dump("CMSConnector:cmsconnector.js:uploadAttachmentToCMS: No attachments to upload. This condition should never occur. " + CMSCONNECTOR_REPORT_BUG + "\n")
+}
+
+/**
+ * Called by the "Upload All to CMS..." entry in the attachment
+ * context menu. Uploads all attachments of a given message
+ * to the same node.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal global object
+ * property currentAttachments.
+ * <p>
+ * currentAttachments is defined in
+ * chrome://messenger/content/msgHdrViewOverlay.js.
+ *
+ * @return {Undefined}
+ */
+function uploadAllAttachmentsToCMS() {
+ var CMSNode = null;
+ var liveAttachments = new Array();
+
+ /* DEBUG */ dump("CMSConnector:cmsconnector.js:uploadAllAttachmentsToCMS: self.currentAttachments \"" + self.currentAttachments + "\"\n");
+
+ // filter out attachments marked as deleted
+ for (var i = 0; i < currentAttachments.length; i++)
+ __filterDeletedAttachments(liveAttachments, self.currentAttachments[i]);
+
+ // check if there are any live attachments left to process
+ if (liveAttachments.length != 0) {
+ // upload all attachments to the same node
+ try {
+ CMSNode = NodeSelector.selectNode();
+ } catch (exception) {
+ if (exception instanceof CMSConnectorAbortException) {
+ /* DEBUG */ dump("CMSConnector:cmsconnector.js:uploadAllAttachmentsToCMS: " + exception.toString() + "\n");
+ return;
+ } else {
+ // not a normal abruption
+ dump("CMSConnector:cmsconnector.js:uploadAllAttachmentsToCMS: " + exception.toString() + "\n");
+ return;
+ }
+ }
+
+ /* Iteration over all live attachments is separated from the filtering above
+ * on purpose, because we want to be able to do asynchronous uploads. If uploading
+ * was done in the same step as the filtering, the upload must be synchronous,
+ * otherwise there is no guarantee that an attachment scheduled for upload
+ * still exists at the time the upload begins. */
+ for (var i = 0; i < liveAttachments.length; i++)
+ __uploadAttachment(CMSNode, liveAttachments[i]);
+ } else dump("CMSConnector:cmsconnector.js:uploadAllAttachmentsToCMS: No attachments to upload. This condition should never occur. " + CMSCONNECTOR_REPORT_BUG + "\n")
+}
+
+/**
+ * Upload an attachment to a specific node on the CMS.
+ *
+ * @private
+ * @param {Object} aCMSNode the node where the attachment should be stored in the CMS
+ * @param {Attachment} aAttachment the attachment to upload
+ * @return {Undefined}
+ * @throws {Error} CMSConnectorAbortException
+ * @throws {Error} CMSConnectorExecutionException
+ */
+function __uploadAttachment(aCMSNode, aAttachment) {
+ alert("CMSConnector:cmsconnector.js:__uploadAttachment() invoked\n\n" +
+ "aAttachment.name: " + aAttachment.name + "\n" +
+ "aAttachment.contentType: " + aAttachment.contentType + "\n" +
+ "aAttachment.uri: " + aAttachment.uri);
+}
+
+/**
+ * Filter out all attachments marked as deleted.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal attachment
+ * object.
+ *
+ * @private
+ * @param {Array} aArray the array into which accepted attachments should be stored
+ * @param {Object} aAttachment the attachment to test
+ * @return {Undefined}
+ */
+function __filterDeletedAttachments(aArray, aAttachment) {
+ if (aAttachment.contentType != XMOZ_DELETED_MIME_TYPE)
+ aArray.push(__createAttachment(aAttachment));
+}
+
+
+/**
+ * Create a new object of type CMSConnector Attachment.
+ * This is not a performance penalty since the attachment
+ * needs to be cloned anyway.
+ * <p>
+ * The creation of a custom attachment object decouples
+ * further processing from Mozilla implementation details.
+ * <p>
+ * This function relies on Mozilla internal implementation
+ * details because of referencing the internal attachment
+ * object.
+ *
+ * @private
+ * @param {Object} aAttachment the attachment to clone
+ * @return {Attachment} a newly created object of type Attachment
+ */
+function __createAttachment(aAttachment) {
+ /* The Mozilla internal aAttachment object contains the
+ * following properties:
+ * aAttachment.contentType
+ * aAttachment.url
+ * aAttachment.displayName
+ * aAttachment.messageUri
+ * aAttachment.isExternalAttachment */
+ return new Attachment(aAttachment.displayName,
+ aAttachment.contentType,
+ aAttachment.url)
+}
Added: public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.xul
===================================================================
--- public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.xul 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/trunk/phoenix/demo/chrome/content/phoenix.xul 2006-05-15 13:03:05 UTC (rev 13306)
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+
+<!--
+# ***** BEGIN LICENSE BLOCK *****
+# Copyright 2006 Wyona AG Zurich
+#
+# This file is part of CMSConnector.
+#
+# CMSConnector is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# CMSConnector is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with CMSConnector; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# ***** END LICENSE BLOCK *****
+-->
+
+<!-- Overlays chrome://messenger/content/msgHdrViewOverlay.xul -->
+
+<!DOCTYPE overlay SYSTEM "chrome://cmsconnector/locale/cmsconnector.dtd">
+
+<overlay id="cmsconnector"
+ xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
+
+ <stringbundle id="uiCMSConnectorStringbundle" src="chrome://cmsconnector/locale/cmsconnector.properties"/>
+
+ <script type="application/x-javascript"
+ src="chrome://cmsconnector/content/common.js"/>
+ <script type="application/x-javascript"
+ src="chrome://cmsconnector/content/cmsconnector.js"/>
+ <script type="application/x-javascript"
+ src="chrome://cmsconnector/content/nodeselector.js"/>
+
+ <!-- Overlay the context menu which opens when right-clicking an attachment or
+ right-clicking somewehere in the attachment area (without selecting an
+ attachment in particular. -->
+ <popup id="attachmentListContext">
+ <menuitem id="context-uploadAttachmentToCMS"
+ insertafter="context-saveAttachment"
+ oncommand="uploadAttachmentToCMS()"
+ label="&uploadAttachmentToCMSCmd.label;"
+ accesskey="&uploadAttachmentToCMSCmd.accesskey;"
+ disabled="true"/>
+ <menuitem id="context-uploadAllAttachmentsToCMS"
+ insertafter="context-saveAllAttachments"
+ oncommand="uploadAllAttachmentsToCMS()"
+ label="&uploadAllAttachmentsToCMSCmd.label;"
+ accesskey="&uploadAllAttachmentsToCMSCmd.accesskey;"
+ disabled="true"/>
+ </popup>
+
+ <!-- Overlay the sub menu of the File -> Attachments menu in the menu bar. -->
+ <popup id="attachmentMenuList">
+ <menuitem id="file-uploadAllAttachmentsToCMS"
+ insertafter="file-saveAllAttachments"
+ oncommand="uploadAllAttachmentsToCMS()"
+ label="&uploadAllAttachmentsToCMSCmd.label;"
+ accesskey="&uploadAllAttachmentsToCMSCmd.accesskey;"
+ disabled="true"/>
+ </popup>
+
+</overlay>
Added: public/phoenix/trunk/phoenix/demo/chrome.manifest
===================================================================
--- public/phoenix/trunk/phoenix/demo/chrome.manifest 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/trunk/phoenix/demo/chrome.manifest 2006-05-15 13:03:05 UTC (rev 13306)
@@ -0,0 +1,4 @@
+content phoenix chrome/content/
+locale phoenix en chrome/locale/en/
+skin phoenix pinstripe chrome/skin/
+overlay chrome://browser/content/browser.xul chrome://phoenix/content/phoenix.xul
Added: public/phoenix/trunk/phoenix/demo/install.rdf
===================================================================
--- public/phoenix/trunk/phoenix/demo/install.rdf 2006-05-15 12:48:23 UTC (rev 13305)
+++ public/phoenix/trunk/phoenix/demo/install.rdf 2006-05-15 13:03:05 UTC (rev 13306)
@@ -0,0 +1,65 @@
+<?xml version="1.0"?>
+
+<!--
+# ***** BEGIN LICENSE BLOCK *****
+# Copyright 2006 Wyona AG Zurich
+#
+# This file is part of Phoenix.
+#
+# Phoenix is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# Phoenix is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with Phoenix; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# ***** END LICENSE BLOCK *****
+-->
+
+<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:em="http://www.mozilla.org/2004/em-rdf#">
+
+ <Description about="urn:mozilla:install-manifest">
+ <em:id>cmsconnector at wyona.com</em:id>
+ <em:version>0.1</em:version>
+ <em:type>2</em:type>
+
+ <!-- Target application is Mozilla Firefox 1.5.0.* -->
+ <em:targetApplication>
+ <Description>
+ <em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>
+ <em:minVersion>1.5.0</em:minVersion>
+ <em:maxVersion>1.5.0.*</em:maxVersion>
+ </Description>
+ </em:targetApplication>
+ <!-- Target application is Mozilla Suite 1.7.* -->
+ <em:targetApplication>
+ <Description>
+ <em:id>{86c18b42-e466-45a9-ae7a-9b95ba6f5640}</em:id>
+ <em:minVersion>1.7</em:minVersion>
+ <em:maxVersion>1.7.*</em:maxVersion>
+ </Description>
+ </em:targetApplication>
+ <!-- Target application is Mozilla SeaMonkey 1.0.* -->
+ <em:targetApplication>
+ <Description>
+ <em:id>{92650c4d-4b8e-4d2a-b7eb-24ecf4f6b63a}</em:id>
+ <em:minVersion>1.0</em:minVersion>
+ <em:maxVersion>1.0.*</em:maxVersion>
+ </Description>
+ </em:targetApplication>
+
+ <!-- Extension information -->
+ <em:name>Wyona Phoenix Editor</em:name>
+ <em:description>Seamless editing of Web content.</em:description>
+ <em:creator>Andreas Wuest</em:creator>
+ <em:homepageURL>http://www.wyona.com/</em:homepageURL>
+ </Description>
+</RDF>
More information about the Phoenix-commits
mailing list