Skip to content

Commit

Permalink
Added Pcoord updates when database changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Orban committed Jun 8, 2018
1 parent 16e165f commit b278ed4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
13 changes: 7 additions & 6 deletions cinema/bandit/1.1/js/Main.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ function load() {
filter,
doneLoading);*/
//First create a database
database = new CINEMA_COMPONENTS.Database(db.directory,doneLoading, null, onDatabaseUpdated);
database = new CINEMA_COMPONENTS.Database(db.directory,doneLoading, null, onDatabaseUpdate);
}

//Called when parallel coordinates chart finishes loading
Expand Down Expand Up @@ -171,11 +171,12 @@ function doneLoading() {
}
}

function onDatabaseUpdated(updateInfo) {
console.log(updateInfo);
chart.updateSelection();
chart.redrawSelectedPaths();
chart.redrawHighlightedPaths();
function onDatabaseUpdate(updateInfo) {
if (updateInfo.added.length > 0) {
visarChart.loadData(updateInfo.added);
diffractionChart.loadData(updateInfo.added);
chart.updateSelection(true);
}
}

//Set up dragging on the resize bar
Expand Down
2 changes: 1 addition & 1 deletion ext/cinema_components

0 comments on commit b278ed4

Please sign in to comment.