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...
This commit is contained in:
parent
b5a7f7ac05
commit
c5e5f1ef2c
|
@ -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();
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue