Mjs.Dialogs.ClearGraph = {
open: function(){
Mjs.Dialogs.ClearGraph._open();
},
_open: function() {
$( "#dialog-clear-graph" ).dialog( "open" );
},
init: function() {
$( "#dialog-clear-graph" ).dialog({
resizable: false,
autoOpen: false,
height:200,
modal: true,
buttons: {
"Delete all items": function() {
// removing all codelines should eventually clear
// all connectors as well.
Mjs.Collections.codelineCollection.removeAll();
$( this ).dialog( "close" );
},
Cancel: function() {
$( this ).dialog( "close" );
}
}
});
}
};