Bug 782488 - Use system messages to notify incoming telephony events. r=philikon

This commit is contained in:
Hsin-Yi Tsai 2012-08-31 11:06:42 +08:00
parent 9fde926bdf
commit bd2a9a3771

View File

@ -763,6 +763,11 @@ RadioInterfaceLayer.prototype = {
handleCallStateChange: function handleCallStateChange(call) {
debug("handleCallStateChange: " + JSON.stringify(call));
call.state = convertRILCallState(call.state);
if (call.state == nsIRadioInterfaceLayer.CALL_STATE_INCOMING) {
gSystemMessenger.broadcastMessage("telephony-incoming", {number: call.number});
}
if (call.isActive) {
this._activeCall = call;
} else if (this._activeCall &&