Large number of small fixes. Multi-select getting closer now (still not working)

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@243 eee81c28-f429-11dd-99c0-75d572ba1ddd
This commit is contained in:
Jeff Schiller
2009-07-01 19:28:08 +00:00
parent 71e3b92e3c
commit 797f53345b
2 changed files with 89 additions and 136 deletions

View File

@@ -20,11 +20,12 @@ function svg_edit_setup() {
var selectedElement = null;
// called when we've selected a different element
var selectedChanged = function(window,elem) {
selectedElement = elem;
if (elem != null) {
var selectedChanged = function(window,elems) {
// if elems[1] is present, then we have more than one element
selectedElement = (elems.length == 1 || elems[1] == null ? elems[0] : null);
if (selectedElement != null) {
// always set the mode of the editor to select because
// unless we're already in always set the mode of the editor to select because
// upon creation of a text element the editor is switched into
// select mode and this event fires - we need our UI to be in sync
if (svgCanvas.getMode() != "multiselect") {