dom/mobilemessage/interfaces/nsIMobileMessageCallback.idl

changeset 0
6474c204b198
equal deleted inserted replaced
-1:000000000000 0:2a81dfbff4eb
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4
5 #include "nsISupports.idl"
6 #include "nsIDOMSmsSegmentInfo.idl"
7
8 [scriptable, uuid(41db87b0-b0a1-11e3-a04f-cf487d837ee3)]
9 interface nsIMobileMessageCallback : nsISupports
10 {
11 /**
12 * All SMS related errors.
13 * Make sure to keep this list in sync with the list in:
14 * embedding/android/GeckoSmsManager.java
15 */
16 const unsigned short SUCCESS_NO_ERROR = 0;
17 const unsigned short NO_SIGNAL_ERROR = 1;
18 const unsigned short NOT_FOUND_ERROR = 2;
19 const unsigned short UNKNOWN_ERROR = 3;
20 const unsigned short INTERNAL_ERROR = 4;
21 const unsigned short NO_SIM_CARD_ERROR = 5;
22 const unsigned short RADIO_DISABLED_ERROR = 6;
23 const unsigned short INVALID_ADDRESS_ERROR = 7;
24 const unsigned short FDN_CHECK_ERROR = 8;
25 const unsigned short NON_ACTIVE_SIM_CARD_ERROR = 9;
26 const unsigned short STORAGE_FULL_ERROR = 10;
27 const unsigned short SIM_NOT_MATCHED_ERROR = 11;
28
29 /**
30 * |message| can be nsIDOMMoz{Mms,Sms}Message.
31 */
32 void notifyMessageSent(in nsISupports message);
33 void notifySendMessageFailed(in long error);
34
35 /**
36 * |message| can be nsIDOMMoz{Mms,Sms}Message.
37 */
38 void notifyMessageGot(in nsISupports message);
39 void notifyGetMessageFailed(in long error);
40
41 void notifyMessageDeleted([array, size_is(count)] in boolean deleted,
42 in uint32_t count);
43 void notifyDeleteMessageFailed(in long error);
44
45 void notifyMessageMarkedRead(in boolean read);
46 void notifyMarkMessageReadFailed(in long error);
47
48 void notifySegmentInfoForTextGot(in nsIDOMMozSmsSegmentInfo info);
49 void notifyGetSegmentInfoForTextFailed(in long error);
50
51 /**
52 * SMSC Address get/set result
53 */
54 void notifyGetSmscAddress(in DOMString aSmscAddress);
55 void notifyGetSmscAddressFailed(in long error);
56 };

mercurial