From c5e5f1ef2c79447b87c646f8207f1d4540f6789a Mon Sep 17 00:00:00 2001 From: Jacques Distler Date: Sat, 6 Feb 2010 01:44:41 -0600 Subject: [PATCH 1/2] Yet Another "Focus" Tweak I'm not that happy with passing the SVG as a Base64-encoded query-parameter. Will have to fix that, too... --- public/javascripts/page_helper.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/public/javascripts/page_helper.js b/public/javascripts/page_helper.js index d769c4f4..c4ed6e18 100644 --- a/public/javascripts/page_helper.js +++ b/public/javascripts/page_helper.js @@ -83,10 +83,13 @@ function setupSVGedit(path){ SVGeditButton.disabled = true; Event.observe(SVGeditButton, 'click', function(){ if (selected) { - var editor = window.open(path +'?source=data:image/svg+xml;base64,' + window.btoa(selected), 'Spoons!'); + var editor = window.open(path +'?source=data:image/svg+xml;base64,' + window.btoa(selected), + 'Editing Existing SVG Graphic'); } else { - var editor = window.open(path, 'Spoons!'); + var editor = window.open(path, 'Creating New SVG graphic'); } + SVGeditButton.disabled = true; + SVGeditButton.value = 'Create SVG graphic'; editor.focus(); }); } From c32e5b7178c4ac50faf1eec1999488c995ca822a Mon Sep 17 00:00:00 2001 From: Jacques Distler Date: Sat, 6 Feb 2010 16:55:49 -0600 Subject: [PATCH 2/2] Sync with SVG-Edit --- public/svg-edit/editor/svg-editor.html | 28 ++++++++++++++------------ public/svg-edit/editor/svgcanvas.js | 4 ++-- 2 files changed, 17 insertions(+), 15 deletions(-) diff --git a/public/svg-edit/editor/svg-editor.html b/public/svg-edit/editor/svg-editor.html index c2fa6738..d2878cb3 100644 --- a/public/svg-edit/editor/svg-editor.html +++ b/public/svg-edit/editor/svg-editor.html @@ -4,7 +4,7 @@ - + @@ -73,7 +73,7 @@ script type="text/javascript" src="locale/locale.min.js"> -
L a y e r s
+
L a y e r s
@@ -231,7 +231,7 @@ script type="text/javascript" src="locale/locale.min.js">
-
-
-
@@ -335,7 +337,7 @@ script type="text/javascript" src="locale/locale.min.js"> - + +
Canvas Dimensions - + - +