From 351e4110f519d18bb36747955578e9e5b9aeec7b Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Fri, 1 Mar 2013 12:28:34 -0800 Subject: [PATCH] altosuilib: Add setNotify/fireSeriesChanged methods to AltosUIGrapher This will let the data adding functions disable notifications while adding all of the graph data, and then send a single notification when the data sets are complete, which speeds up creating of the graph elements quite a bit. Signed-off-by: Keith Packard --- altosuilib/AltosUIGrapher.java | 4 ++++ altosuilib/AltosUIMarker.java | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/altosuilib/AltosUIGrapher.java b/altosuilib/AltosUIGrapher.java index c627fec5..8f0ce801 100644 --- a/altosuilib/AltosUIGrapher.java +++ b/altosuilib/AltosUIGrapher.java @@ -43,4 +43,8 @@ interface AltosUIGrapher { public abstract void add(AltosUIDataPoint dataPoint); public abstract void set_enable(boolean enable); + + public abstract void setNotify(boolean notify); + + public abstract void fireSeriesChanged(); } diff --git a/altosuilib/AltosUIMarker.java b/altosuilib/AltosUIMarker.java index e2eb9028..0949be6f 100644 --- a/altosuilib/AltosUIMarker.java +++ b/altosuilib/AltosUIMarker.java @@ -100,6 +100,12 @@ public class AltosUIMarker implements AltosUIGrapher { this.enabled = enable; } + public void setNotify(boolean notify) { + } + + public void fireSeriesChanged() { + } + public AltosUIMarker (int fetch, Color color, XYPlot plot) { this(fetch, color, plot, true); } -- 2.30.2