Bug 1256414 - Hide MozSettingsEvent from the Web; r=khuey

MozSettingsTransactionEvent is already hidden behind this permission, so
it makes sense to require the same permissions for this event too.
This commit is contained in:
Ehsan Akhgari 2016-03-13 15:24:59 -04:00
parent 17ed0683ac
commit c4d18616e2
2 changed files with 3 additions and 2 deletions

View File

@ -834,7 +834,7 @@ var interfaceNamesInGlobalScope =
// IMPORTANT: Do not change this list without review from a DOM peer!
"mozRTCSessionDescription",
// IMPORTANT: Do not change this list without review from a DOM peer!
"MozSettingsEvent",
{name: "MozSettingsEvent", permission: ["settings-api-read"]},
// IMPORTANT: Do not change this list without review from a DOM peer!
{name: "MozSettingsTransactionEvent", permission: ["settings-api-read"]},
// IMPORTANT: Do not change this list without review from a DOM peer!

View File

@ -4,7 +4,8 @@
* You can obtain one at http://mozilla.org/MPL/2.0/.
*/
[Constructor(DOMString type, optional MozSettingsEventInit eventInitDict)]
[Constructor(DOMString type, optional MozSettingsEventInit eventInitDict),
CheckAnyPermissions="settings-api-read settings-api-write"]
interface MozSettingsEvent : Event
{
readonly attribute DOMString? settingName;