From 709665fa30fe8b704aa1dfa2a80e3c7e7adebdca Mon Sep 17 00:00:00 2001 From: Bevis Tseng Date: Mon, 28 Apr 2014 12:33:10 +0800 Subject: [PATCH] Bug 824717 - Part 3: Modify nsIMobileMessageCallback::notifySendMessageFailed() to accept an additional nsISupports message. r=vyang --- dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl | 4 ++-- dom/mobilemessage/src/MobileMessageCallback.cpp | 2 +- dom/mobilemessage/src/ipc/SmsChild.cpp | 3 ++- dom/mobilemessage/src/ipc/SmsParent.cpp | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl b/dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl index 8de1dcccc276..31bcca4158e5 100644 --- a/dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl +++ b/dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl @@ -5,7 +5,7 @@ #include "nsISupports.idl" #include "nsIDOMSmsSegmentInfo.idl" -[scriptable, uuid(41db87b0-b0a1-11e3-a04f-cf487d837ee3)] +[scriptable, uuid(0e6f8ace-cc59-11e3-aad5-e32847abfda1)] interface nsIMobileMessageCallback : nsISupports { /** @@ -30,7 +30,7 @@ interface nsIMobileMessageCallback : nsISupports * |message| can be nsIDOMMoz{Mms,Sms}Message. */ void notifyMessageSent(in nsISupports message); - void notifySendMessageFailed(in long error); + void notifySendMessageFailed(in long error, in nsISupports message); /** * |message| can be nsIDOMMoz{Mms,Sms}Message. diff --git a/dom/mobilemessage/src/MobileMessageCallback.cpp b/dom/mobilemessage/src/MobileMessageCallback.cpp index 26b08bf18adb..117929df953d 100644 --- a/dom/mobilemessage/src/MobileMessageCallback.cpp +++ b/dom/mobilemessage/src/MobileMessageCallback.cpp @@ -138,7 +138,7 @@ MobileMessageCallback::NotifyMessageSent(nsISupports *aMessage) } NS_IMETHODIMP -MobileMessageCallback::NotifySendMessageFailed(int32_t aError) +MobileMessageCallback::NotifySendMessageFailed(int32_t aError, nsISupports *aMessage) { return NotifyError(aError); } diff --git a/dom/mobilemessage/src/ipc/SmsChild.cpp b/dom/mobilemessage/src/ipc/SmsChild.cpp index 7e3f12b44a9d..11950a30d231 100644 --- a/dom/mobilemessage/src/ipc/SmsChild.cpp +++ b/dom/mobilemessage/src/ipc/SmsChild.cpp @@ -192,7 +192,8 @@ SmsRequestChild::Recv__delete__(const MessageReply& aReply) } break; case MessageReply::TReplyMessageSendFail: - mReplyRequest->NotifySendMessageFailed(aReply.get_ReplyMessageSendFail().error()); + mReplyRequest->NotifySendMessageFailed( + aReply.get_ReplyMessageSendFail().error(), nullptr); break; case MessageReply::TReplyGetMessage: { const MobileMessageData& data = diff --git a/dom/mobilemessage/src/ipc/SmsParent.cpp b/dom/mobilemessage/src/ipc/SmsParent.cpp index a6510699078f..82c1e5badb9a 100644 --- a/dom/mobilemessage/src/ipc/SmsParent.cpp +++ b/dom/mobilemessage/src/ipc/SmsParent.cpp @@ -639,7 +639,7 @@ SmsRequestParent::NotifyMessageSent(nsISupports *aMessage) } NS_IMETHODIMP -SmsRequestParent::NotifySendMessageFailed(int32_t aError) +SmsRequestParent::NotifySendMessageFailed(int32_t aError, nsISupports *aMessage) { return SendReply(ReplyMessageSendFail(aError)); }