A few months ago I discovered that the Google Analytics Java library for Android can interfere with the performance of your application because it accesses a database on the main thread.
Not wanting to abandon analytics, I’ve been using this class ever since. It’s a useful wrapper around the GoogleAnalyticsTracker class which I thought I’d share because it’s simply very useful. It:
Using it is very simple, here’s an example:
And here’s the class which you’re welcome to use in any of your own projects.