mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 01:48:05 +00:00
Backed out changeset 033708b53979 (bug 958782) for bustage on a CLOSED TREE
--HG-- rename : dom/webidl/MozMobileMessageManager.webidl => dom/webidl/MobileMessageManager.webidl
This commit is contained in:
parent
87dcb8380c
commit
723aa94650
@ -842,10 +842,6 @@ DOMInterfaces = {
|
||||
'nativeType': 'mozilla::dom::MobileConnectionInfo',
|
||||
},
|
||||
|
||||
'MozMobileMessageManager': {
|
||||
'nativeType': 'mozilla::dom::MobileMessageManager',
|
||||
},
|
||||
|
||||
'MozMobileNetworkInfo': {
|
||||
'nativeType': 'mozilla::dom::MobileNetworkInfo',
|
||||
},
|
||||
@ -1964,13 +1960,11 @@ addExternalIface('MozFrameLoader', nativeType='nsIFrameLoader', notflattened=Tru
|
||||
addExternalIface('MozFrameRequestCallback', nativeType='nsIFrameRequestCallback',
|
||||
notflattened=True)
|
||||
addExternalIface('MozIccInfo', headerFile='nsIDOMIccInfo.h')
|
||||
addExternalIface('MozMmsMessage')
|
||||
addExternalIface('MozMobileMessageManager', headerFile='nsIDOMMobileMessageManager.h')
|
||||
addExternalIface('MozObserver', nativeType='nsIObserver', notflattened=True)
|
||||
addExternalIface('MozRDFCompositeDataSource', nativeType='nsIRDFCompositeDataSource',
|
||||
notflattened=True)
|
||||
addExternalIface('MozRDFResource', nativeType='nsIRDFResource', notflattened=True)
|
||||
addExternalIface('MozSmsFilter', headerFile='nsIDOMSmsFilter.h')
|
||||
addExternalIface('MozSmsMessage')
|
||||
addExternalIface('MozTreeBoxObject', nativeType='nsITreeBoxObject',
|
||||
notflattened=True)
|
||||
addExternalIface('MozTreeColumn', nativeType='nsITreeColumn',
|
||||
|
@ -5,6 +5,7 @@
|
||||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
XPIDL_SOURCES += [
|
||||
'nsIDOMMobileMessageManager.idl',
|
||||
'nsIDOMMozMmsMessage.idl',
|
||||
'nsIDOMMozMobileMessageThread.idl',
|
||||
'nsIDOMMozSmsMessage.idl',
|
||||
|
81
dom/mobilemessage/interfaces/nsIDOMMobileMessageManager.idl
Normal file
81
dom/mobilemessage/interfaces/nsIDOMMobileMessageManager.idl
Normal file
@ -0,0 +1,81 @@
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#include "nsIDOMEventTarget.idl"
|
||||
|
||||
interface nsIDOMEventListener;
|
||||
interface nsIDOMMozSmsFilter;
|
||||
interface nsIDOMMozSmsSegmentInfo;
|
||||
interface nsIDOMDOMCursor;
|
||||
interface nsIDOMDOMRequest;
|
||||
interface nsIDOMBlob;
|
||||
|
||||
[scriptable, builtinclass, uuid(8ec8247d-3f5f-41af-9c72-9dc857e3be81)]
|
||||
interface nsIDOMMozMobileMessageManager : nsIDOMEventTarget
|
||||
{
|
||||
nsIDOMDOMRequest getSegmentInfoForText(in DOMString text);
|
||||
|
||||
|
||||
/**
|
||||
* Function to send SMS.
|
||||
*
|
||||
* @param number
|
||||
* Either a DOMString (only one number) or an array of numbers.
|
||||
* @param message
|
||||
* The text message to be sent.
|
||||
* @param sendParameters
|
||||
* An SmsSendParameters object.
|
||||
* @param return
|
||||
* A DOMRequest object indicating the sending result if one number
|
||||
* has been passed; an array of DOMRequest objects otherwise.
|
||||
*/
|
||||
[implicit_jscontext, optional_argc]
|
||||
jsval send(in jsval number, in DOMString message,
|
||||
[optional] in jsval sendParameters);
|
||||
|
||||
/**
|
||||
* Function to send MMS.
|
||||
*
|
||||
* @param parameters
|
||||
* An MmsParameters object.
|
||||
* @param sendParameters
|
||||
* An MmsSendParameters object.
|
||||
* @param return
|
||||
* A DOMRequest object indicating the sending result.
|
||||
*/
|
||||
[implicit_jscontext, optional_argc]
|
||||
nsIDOMDOMRequest sendMMS(in jsval parameters,
|
||||
[optional] in jsval sendParameters);
|
||||
|
||||
[binaryname(GetMessageMoz)]
|
||||
nsIDOMDOMRequest getMessage(in long id);
|
||||
|
||||
// The parameter can be either a message id or a nsIDOMMoz{Mms,Sms}Message.
|
||||
[implicit_jscontext]
|
||||
nsIDOMDOMRequest delete(in jsval param);
|
||||
|
||||
// Iterates through nsIDOMMoz{Mms,Sms}Message.
|
||||
nsIDOMDOMCursor getMessages(in nsIDOMMozSmsFilter filter, in boolean reverse);
|
||||
|
||||
nsIDOMDOMRequest markMessageRead(in long id, in boolean value,
|
||||
[optional] in boolean aSendReadReport);
|
||||
|
||||
// Iterates through nsIDOMMozMobileMessageThread.
|
||||
nsIDOMDOMCursor getThreads();
|
||||
|
||||
nsIDOMDOMRequest retrieveMMS(in long id);
|
||||
|
||||
[optional_argc]
|
||||
nsIDOMDOMRequest getSmscAddress([optional] in unsigned long serviceId);
|
||||
|
||||
[implicit_jscontext] attribute jsval onreceived;
|
||||
[implicit_jscontext] attribute jsval onretrieving;
|
||||
[implicit_jscontext] attribute jsval onsending;
|
||||
[implicit_jscontext] attribute jsval onsent;
|
||||
[implicit_jscontext] attribute jsval onfailed;
|
||||
[implicit_jscontext] attribute jsval ondeliverysuccess;
|
||||
[implicit_jscontext] attribute jsval ondeliveryerror;
|
||||
[implicit_jscontext] attribute jsval onreadsuccess;
|
||||
[implicit_jscontext] attribute jsval onreaderror;
|
||||
};
|
24
dom/webidl/MobileMessageManager.webidl
Normal file
24
dom/webidl/MobileMessageManager.webidl
Normal file
@ -0,0 +1,24 @@
|
||||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
dictionary MmsParameters {
|
||||
sequence<DOMString> receivers;
|
||||
DOMString? subject = null;
|
||||
DOMString? smil = null;
|
||||
sequence<MmsAttachment> attachments;
|
||||
};
|
||||
|
||||
// If we start using MmsParameters here, remove it from DummyBinding.
|
||||
|
||||
dictionary SmsSendParameters {
|
||||
unsigned long serviceId; // The ID of the RIL service which needs to be
|
||||
// specified under the multi-sim scenario.
|
||||
};
|
||||
|
||||
dictionary MmsSendParameters {
|
||||
unsigned long serviceId; // The ID of the RIL service which needs to be
|
||||
// specified under the multi-sim scenario.
|
||||
};
|
@ -4,6 +4,13 @@
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
// If this is changed, change the MmsMessage.h structure as well.
|
||||
dictionary MmsAttachment {
|
||||
DOMString? id = null;
|
||||
DOMString? location = null;
|
||||
Blob? content = null;
|
||||
};
|
||||
|
||||
dictionary MmsDeliveryInfo {
|
||||
DOMString? receiver = null;
|
||||
DOMString? deliveryStatus = null;
|
||||
@ -13,3 +20,5 @@ dictionary MmsDeliveryInfo {
|
||||
DOMTimeStamp readTimestamp = 0; // 0 if not available (e.g.,
|
||||
// |delivery| = "received" or not yet read).
|
||||
};
|
||||
|
||||
// If we start using MmsParameters here, remove it from DummyBinding.
|
||||
|
@ -1,123 +0,0 @@
|
||||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
interface MozMmsMessage;
|
||||
interface MozSmsFilter;
|
||||
interface MozSmsMessage;
|
||||
|
||||
dictionary MmsAttachment {
|
||||
DOMString? id = null;
|
||||
DOMString? location = null;
|
||||
Blob? content = null;
|
||||
};
|
||||
|
||||
dictionary MmsParameters {
|
||||
sequence<DOMString> receivers;
|
||||
DOMString? subject = null;
|
||||
DOMString? smil = null;
|
||||
sequence<MmsAttachment> attachments;
|
||||
};
|
||||
|
||||
dictionary SmsSendParameters {
|
||||
unsigned long serviceId; // The ID of the RIL service which needs to be
|
||||
// specified under the multi-sim scenario.
|
||||
};
|
||||
|
||||
dictionary MmsSendParameters {
|
||||
unsigned long serviceId; // The ID of the RIL service which needs to be
|
||||
// specified under the multi-sim scenario.
|
||||
};
|
||||
|
||||
[Pref="dom.sms.enabled"]
|
||||
interface MozMobileMessageManager : EventTarget
|
||||
{
|
||||
[Throws]
|
||||
DOMRequest getSegmentInfoForText(DOMString text);
|
||||
|
||||
/**
|
||||
* Send SMS.
|
||||
*
|
||||
* @param number
|
||||
* Either a DOMString (only one number) or an array of numbers.
|
||||
* @param text
|
||||
* The text message to be sent.
|
||||
* @param sendParameters
|
||||
* A SmsSendParameters object.
|
||||
*
|
||||
* @return
|
||||
* A DOMRequest object indicating the sending result if one number
|
||||
* has been passed; an array of DOMRequest objects otherwise.
|
||||
*/
|
||||
[Throws]
|
||||
DOMRequest send(DOMString number,
|
||||
DOMString text,
|
||||
optional SmsSendParameters sendParameters);
|
||||
[Throws]
|
||||
sequence<DOMRequest> send(sequence<DOMString> numbers,
|
||||
DOMString text,
|
||||
optional SmsSendParameters sendParameters);
|
||||
|
||||
/**
|
||||
* Send MMS.
|
||||
*
|
||||
* @param parameters
|
||||
* A MmsParameters object.
|
||||
* @param sendParameters
|
||||
* A MmsSendParameters object.
|
||||
*
|
||||
* @return
|
||||
* A DOMRequest object indicating the sending result.
|
||||
*/
|
||||
[Throws]
|
||||
DOMRequest sendMMS(optional MmsParameters parameters,
|
||||
optional MmsSendParameters sendParameters);
|
||||
|
||||
[Throws]
|
||||
DOMRequest getMessage(long id);
|
||||
|
||||
// The parameter can be either a message id, or a Moz{Mms,Sms}Message, or an
|
||||
// array of Moz{Mms,Sms}Message objects.
|
||||
[Throws]
|
||||
DOMRequest delete(long id);
|
||||
[Throws]
|
||||
DOMRequest delete(MozSmsMessage message);
|
||||
[Throws]
|
||||
DOMRequest delete(MozMmsMessage message);
|
||||
[Throws]
|
||||
DOMRequest delete(sequence<(long or MozSmsMessage or MozMmsMessage)> params);
|
||||
|
||||
// Iterates through Moz{Mms,Sms}Message.
|
||||
[Throws]
|
||||
DOMCursor getMessages(optional MozSmsFilter? filter = null,
|
||||
optional boolean reverse = false);
|
||||
|
||||
[Throws]
|
||||
DOMRequest markMessageRead(long id,
|
||||
boolean read,
|
||||
optional boolean sendReadReport = false);
|
||||
|
||||
// Iterates through nsIDOMMozMobileMessageThread.
|
||||
[Throws]
|
||||
DOMCursor getThreads();
|
||||
|
||||
[Throws]
|
||||
DOMRequest retrieveMMS(long id);
|
||||
[Throws]
|
||||
DOMRequest retrieveMMS(MozMmsMessage message);
|
||||
|
||||
[Throws]
|
||||
DOMRequest getSmscAddress(optional unsigned long serviceId);
|
||||
|
||||
attribute EventHandler onreceived;
|
||||
attribute EventHandler onretrieving;
|
||||
attribute EventHandler onsending;
|
||||
attribute EventHandler onsent;
|
||||
attribute EventHandler onfailed;
|
||||
attribute EventHandler ondeliverysuccess;
|
||||
attribute EventHandler ondeliveryerror;
|
||||
attribute EventHandler onreadsuccess;
|
||||
attribute EventHandler onreaderror;
|
||||
};
|
@ -245,6 +245,8 @@ partial interface Navigator {
|
||||
boolean mozIsLocallyAvailable(DOMString uri, boolean whenOffline);
|
||||
};
|
||||
|
||||
// nsIDOMMozNavigatorMobileMessage
|
||||
interface MozMobileMessageManager;
|
||||
partial interface Navigator {
|
||||
[Func="Navigator::HasMobileMessageSupport"]
|
||||
readonly attribute MozMobileMessageManager? mozMobileMessage;
|
||||
|
@ -250,11 +250,11 @@ WEBIDL_FILES = [
|
||||
'MessagePortList.webidl',
|
||||
'MimeType.webidl',
|
||||
'MimeTypeArray.webidl',
|
||||
'MobileMessageManager.webidl',
|
||||
'MouseEvent.webidl',
|
||||
'MouseScrollEvent.webidl',
|
||||
'MozActivity.webidl',
|
||||
'MozMmsMessage.webidl',
|
||||
'MozMobileMessageManager.webidl',
|
||||
'MozNamedAttrMap.webidl',
|
||||
'MozPowerManager.webidl',
|
||||
'MozTimeManager.webidl',
|
||||
|
Loading…
Reference in New Issue
Block a user