Add onDeviceReady for Phonegap