protected internal override void onResume() { base.onResume(); if (mChartView == null) { LinearLayout layout = (LinearLayout)findViewById(R.id.chart); // mChartView = ChartFactory.getLineChartView(this, mDataset, mRenderer); // mChartView = ChartFactory.getBarChartView(this, mDataset, mRenderer, // Type.DEFAULT); mChartView = ChartFactory.getScatterChartView(this, mDataset, mRenderer); // enable the chart click events mRenderer.ClickEnabled = true; mRenderer.SelectableBuffer = 100; mChartView.OnClickListener = new OnClickListenerAnonymousInnerClassHelper3(this); // an example of handling the zoom events on the chart mChartView.addZoomListener(new ZoomListenerAnonymousInnerClassHelper(this), true, true); // an example of handling the pan events on the chart mChartView.addPanListener(new PanListenerAnonymousInnerClassHelper(this)); layout.addView(mChartView, new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); bool enabled = mDataset.SeriesCount > 0; SeriesWidgetsEnabled = enabled; } else { mChartView.repaint(); } }
protected internal override void onResume() { base.onResume(); if (mChartView == null) { LinearLayout layout = (LinearLayout)findViewById(R.id.chart); mChartView = ChartFactory.getLineChartView(this, mDataset, mRenderer); // enable the chart click events mRenderer.ClickEnabled = true; mRenderer.SelectableBuffer = 10; mChartView.OnClickListener = new OnClickListenerAnonymousInnerClassHelper3(this); layout.addView(mChartView, new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); bool enabled = mDataset.SeriesCount > 0; SeriesWidgetsEnabled = enabled; } else { mChartView.repaint(); } }