forked from mozilla/gecko-dev
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug 898445 - Part 1-2: Move MozMobileNetworkInfo to webidl. r=hsinyi,…
…smaug
- Loading branch information
Showing
5 changed files
with
74 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/* 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 "nsISupports.idl" | ||
|
||
[scriptable, uuid(d7e1364c-61a0-4cf1-bae3-a960e87064e1)] | ||
interface nsIMobileNetworkInfo: nsISupports | ||
{ | ||
/** | ||
* Short name of the network operator. | ||
*/ | ||
readonly attribute DOMString shortName; | ||
|
||
/** | ||
* Long name of the network operator. | ||
*/ | ||
readonly attribute DOMString longName; | ||
|
||
/** | ||
* Mobile Country Code (MCC) of the network operator. | ||
*/ | ||
readonly attribute DOMString mcc; | ||
|
||
/** | ||
* Mobile Network Code (MNC) of the network operator. | ||
*/ | ||
readonly attribute DOMString mnc; | ||
|
||
/** | ||
* State of this network operator. | ||
* | ||
* Possible values: 'available', 'connected', 'forbidden', or null (unknown). | ||
*/ | ||
readonly attribute DOMString state; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/* 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/. */ | ||
|
||
enum MobileNetworkState {"available", "connected", "forbidden"}; | ||
|
||
[Pref="dom.mobileconnection.enabled", | ||
ChromeConstructor(DOMString shortName, DOMString longName, DOMString mcc, | ||
DOMString mnc, DOMString state)] | ||
interface MozMobileNetworkInfo | ||
{ | ||
/** | ||
* Short name of the network operator. | ||
*/ | ||
readonly attribute DOMString? shortName; | ||
|
||
/** | ||
* Long name of the network operator. | ||
*/ | ||
readonly attribute DOMString? longName; | ||
|
||
/** | ||
* Mobile Country Code (MCC) of the network operator. | ||
*/ | ||
readonly attribute DOMString? mcc; | ||
|
||
/** | ||
* Mobile Network Code (MNC) of the network operator. | ||
*/ | ||
readonly attribute DOMString? mnc; | ||
|
||
/** | ||
* State of this network operator. | ||
*/ | ||
readonly attribute MobileNetworkState? state; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters