Phonegap-Skipped 33 frames! The application may be doing too much work on its main thread

10,714

This is because Choreographer of android is not getting required resource for performing proper display hence skipping frames.

this mainly happens when user perform heavy operations in main thread, remember Android is single threaded system, there is Single main thread where all the other subsystem hooks upon to perform task such as Activities,Services,Content Providers. thats why when you perform network operation directly on main thered you get Application not responding message.

To elaborate upon your situation, do the following.

  1. If you have any network operation being done in main thread, move them to a separate thread, in Android native we have AsyncTask for that, try finding thread mechanism in Phonegap

  2. If you have any heavy operations such as Compression of Bitmap etc, handle them efficiently by threads or post runnable logic, this will make sure your main thread is free for trivial task such as generation of display processing of events etc.

In the sense, any logic which might take some time, move it to threads, this will make sure your display run smooth.

Hope it help.

Share:
10,714

Related videos on Youtube

user2750238
Author by

user2750238

Updated on September 15, 2022

Comments

  • user2750238
    user2750238 over 1 year

    I'm new for the development of android-phonegap application. I want to display the students details from a database in the server. When i tried to connect with database, it shows me "Skipped 33 frames! The application may be doing too much work on its main thread" in eclipse IDE.

    Please give me solution, or suggestion if any.

  • GMan
    GMan over 10 years
    I am using a web based app - i.e. phonegap and I am getting this issue.. i'm not sure how to work around it?
  • DarkDust
    DarkDust about 10 years
    Note that "using a main/UI thread" is not the same as "single threaded": Android does support multiple threads. Other than that, +1