2013-08-20 35 views
1

下面的代碼來自PhoneGap 3.0生成的index.js,我的問題是爲什麼它不能讓我們像往常一樣使用this.receivedEvent(並將事件對象作爲參數)。爲什麼在onDeviceReady中這是不是像往常一樣?

// The scope of 'this' is the event. In order to call the 'receivedEvent' 
// function, we must explicity call 'app.receivedEvent(...);' 
onDeviceReady: function() { 
    app.receivedEvent('deviceready'); 
}, 

感謝,

回答