Check in patch from Thinker Li to adapt SVG-edit into a Firefox extension

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@429 eee81c28-f429-11dd-99c0-75d572ba1ddd
master
Jeff Schiller 2009-08-21 12:33:56 +00:00
parent 790c3402d5
commit dfd747f9c5
6 changed files with 56 additions and 0 deletions

8
firefox-extension/build.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/sh
DST="content/editor"
if [ -e "${DST}" ]; then
rm -rf "${DST}"
fi
cp -R ../editor content/
SVNS=`find content/editor -name '.svn'`
rm -rf ${SVNS}

View File

@ -0,0 +1,2 @@
content SVG-edit content/
overlay chrome://browser/content/browser.xul chrome://SVG-edit/content/SVG-edit-overlay.xul

View File

@ -0,0 +1,7 @@
function start_svg_edit() {
var url = "chrome://SVG-edit/content/editor/svg-editor.html";
var browser = document.getElementById("content");
window.openDialog(url, "SVG Editor",
"width=1024,height=700,menubar=no,toolbar=no");
}

View File

@ -0,0 +1,14 @@
<?xml version="1.0"?>
<!DOCTYPE overlay SYSTEM "chrome://chromelist/locale/ChromeListOverlay.dtd" >
<overlay id="SVGEditToolsOverlay"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<script type="application/x-javascript"
src="chrome://SVG-edit/content/SVG-edit-overlay.js" />
<menupopup id="menu_ToolsPopup">
<menuitem insertafter="devToolsSeparator" label="SVG Editor"
oncommand="start_svg_edit();" />
</menupopup>
</overlay>

View File

@ -0,0 +1,21 @@
<?xml version="1.0"?>
<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:extension:file:chrome"
em:package="content" />
<Description about="urn:mozilla:install-manifest">
<!-- required properties -->
<em:id>svg-edit@googlegroups.com</em:id>
<em:version>2.2</em:version>
<em:type>2</em:type>
<em:targetApplication>
<Description>
<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>
<em:minVersion>1.5</em:minVersion>
<em:maxVersion>3.*</em:maxVersion>
</Description>
</em:targetApplication>
<em:name>SVG-edit</em:name>
</Description>
</RDF>

4
firefox-extension/mk_xpi.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
./build.sh
zip -r ../svg-edit.xpi *