add deviceready event functionality