I have created an android app that works as designed. However, onCreate() uses dynamic(not xml) to create 80% of my layout,which are consist of buttons. It takes about 3-4 second to build the entire layout, which is too slow. Is there any suggestions to speed up this process?
Things I tried:
1. using fewer view objects, it has not improved the speed and using listview and linearview had very minimal gains
2. I tried moving some of my to onResume(), no gain
3. using serializer to keep my view in sharedpreferences did not work
Are there any ways to speed up dynamic view creation?
have you thought about using a List View and inflating a custom view from xml into the convert views which are recycled?
I don’t know if this would work in your case since I don’t know what your code does but this seems like the proper place ot use an adapter and some sort of List element