Phonegap device ready event

PhoneGap introduces a deviceready event. For every PhoneGap device API access, we need to call it after the device is ready (for PhoneGap).

1$(document).bind("deviceready", function(){
2  app.loadDrawingsFromDB(function(){
3    app.view.renderDrawings(app.drawings);
4  });
5});

What’s next? We’re going to take a look at “Challenge – Adding Color”.

overlaied image when clicked on thumbnail

Makzan | Mobile web app dev with phonegap | Table of Content