diff --git a/src/main/java/org/solovyev/android/calculator/plot/CalculatorPlotActivity.java b/src/main/java/org/solovyev/android/calculator/plot/CalculatorPlotActivity.java index 7173f741..4e83ad13 100644 --- a/src/main/java/org/solovyev/android/calculator/plot/CalculatorPlotActivity.java +++ b/src/main/java/org/solovyev/android/calculator/plot/CalculatorPlotActivity.java @@ -21,7 +21,7 @@ import jscl.math.function.Constant; import jscl.text.ParseException; import org.achartengine.ChartFactory; import org.achartengine.GraphicalView; -import org.achartengine.chart.LineChart; +import org.achartengine.chart.CubicLineChart; import org.achartengine.chart.PointStyle; import org.achartengine.chart.XYChart; import org.achartengine.model.XYMultipleSeriesDataset; @@ -46,6 +46,8 @@ import java.io.Serializable; */ public class CalculatorPlotActivity extends Activity { + private static final String TAG = CalculatorPlotActivity.class.getSimpleName(); + private static final int DEFAULT_NUMBER_OF_STEPS = 100; private static final int DEFAULT_MIN_NUMBER = -10; @@ -160,6 +162,7 @@ public class CalculatorPlotActivity extends Activity { graphicalView.addPanListener(new PanListener() { @Override public void panApplied() { + Log.d(TAG, "org.achartengine.tools.PanListener.panApplied"); updateDataSets(chart); } @@ -182,6 +185,9 @@ public class CalculatorPlotActivity extends Activity { synchronized (pendingOperation) { //lock all operations with history if (pendingOperation.getObject() == this) { + + Log.d(TAG, "org.solovyev.android.calculator.plot.CalculatorPlotActivity.updateDataSets"); + final XYMultipleSeriesRenderer dr = chart.getRenderer(); //Log.d(CalculatorPlotActivity.class.getName(), "x = [" + dr.getXAxisMin() + ", " + dr.getXAxisMax() + "], y = [" + dr.getYAxisMin() + ", " + dr.getYAxisMax() + "]"); @@ -259,7 +265,7 @@ public class CalculatorPlotActivity extends Activity { renderer.addSeriesRenderer(createImagRenderer()); } - return new LineChart(data, renderer); + return new CubicLineChart(data, renderer, 0.1f); } private static XYSeriesRenderer createImagRenderer() {