문제

I am using JFreeChart ( http://www.jfree.org/jfreechart/ ) as a charting library. But for Android I use DroidCharts ( http://code.google.com/p/droidcharts/) which is basically JFreechart for Android. I have created a chart on android. Initially it is clear, then I can add some values to plot and it plots on the chart.

When I rotate my android orientation from portrait to landscape, the screen is blank once again due to the android lifecycle (it goes on to destroy and onCreate is called once again).

I need to know how can I save my plot points using "onSaveInstanceState" to create once again on "onRestoreInstanceState" when the orientation is changed. ? Any code snippet would be helpful . Thanks

도움이 되었습니까?

해결책

as this link suggests:you have to save values in object

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top