[Android 1.6.0] - DataAdapter fireUpdates is slowing interaction


#1

Hi Guys, 

I’ve been trying to figure out what is slowing down interactions with the Shinobi chart, and have tracked it down to fireUpdates. The issue is that there’s currently no way, that I know of, to send partial updates of my data set to Shinobi. What I am finding is that the transfer of the data to Shinobi is taking 80ms sometimes. This leads to many frames being dropped.

Is there any plans to design some more efficient ways of telling Shinobi which data to load? Or providing ways of sending Shinobi data in the background safely?

Thanks in advance.

Neal


#2

Hi Neal,

as far as I know the SimpleDataAdpater fires an Update event every time you add a single datapoint to it.

Extend DataAdpater<?,?> change your dataset and then call  the fireUpdateHandler() method of Dataadapter one time.

regards

Holger


#3

Hi guys,

Yes that’s absolutely right - the SimpleDataAdapter fires an update every time you add, remove or clear data points. As Holger suggested, if you want a different behaviour then extending DataAdapter and using the fireUpdateHandler() (protected) method is the way to go.

The CustomDataAdapter sample app, included in the download bundle, gives an example of doing this.

Kind regards,

Patrick