Instantly refresh visualizations on setting changes

This commit is contained in:
guerler
2018-02-11 14:41:52 -05:00
parent 4fa486082c
commit f2335fe461
2 changed files with 5 additions and 3 deletions
@@ -66,12 +66,13 @@ var GroupView = Backbone.View.extend({
cls: "ui-portlet-plain",
onchange: function() {
self.group.set(self.form.data.create());
self.chart.set("modified", true);
self.chart.trigger("redraw");
}
});
self.group.set(self.form.data.create());
self.$el.empty().append(self.form.$el);
process.resolve();
self.chart.trigger("redraw");
}
});
});
@@ -105,8 +106,8 @@ export default Backbone.View.extend({
this.listenTo(this.chart, "change", function() {
self.render();
});
this.listenTo(this.chart.groups, "add remove reset", function() {
self.chart.set("modified", true);
this.listenTo(this.chart.groups, "remove reset", function() {
self.chart.trigger("redraw")
});
this.listenTo(this.chart.groups, "remove", function(group) {
self.repeat.del(group.id);
@@ -39,6 +39,7 @@ export default Backbone.View.extend({
cls: "ui-portlet-plain",
onchange: function() {
self.chart.settings.set(self.form.data.create());
self.chart.trigger("redraw");
}
});
this.chart.settings.set(this.form.data.create());