1
0
Fork 0

GraphViewer: Toolbox now created correctly

This commit is contained in:
Michael Hackstein 2013-04-12 10:58:54 +02:00
parent e49dbac52f
commit 4bfdf68b5c
3 changed files with 9 additions and 10 deletions

View File

@ -148,6 +148,7 @@
expect(group.children.length).toEqual(2);
// Correctness of buttons is checked in eventDispatcherUISpec.
});
return true;
}
});
});

View File

@ -136,7 +136,7 @@ function EventDispatcherControls(list, nodeShaper, edgeShaper, dispatcherConfig)
rebindNodes({click: nodeCallback});
rebindEdges({click: edgeCallback});
};
createIcon("edit", "edit", callback);
createIcon("pencil", "edit", callback);
};
this.addControlExpand = function() {

View File

@ -74,17 +74,15 @@ function GraphViewerUI(container, adapterConfig) {
},
createToolbox = function() {
var toolbox = document.createElement("div"),
toollist = document.createElement("ul"),
dispatcherUI = new EventDispatcherControls(
toollist,
graphViewer.nodeShaper,
graphViewer.edgeShaper,
graphViewer.dispatcherConfig
);
dispatcherUI = new EventDispatcherControls(
toolbox,
graphViewer.nodeShaper,
graphViewer.edgeShaper,
graphViewer.dispatcherConfig
);
toolbox.id = "toolbox";
toolbox.className = "toolbox pull-left";
toolbox.className = "btn-group btn-group-vertical pull-left toolbox";
container.appendChild(toolbox);
toolbox.appendChild(toollist);
dispatcherUI.addAll();
},
createMenu = function() {