1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/dom/webidl/StorageEvent.webidl Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,42 @@ 1.4 +/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this file, 1.7 + * You can obtain one at http://mozilla.org/MPL/2.0/. 1.8 + * 1.9 + * Interface for a client side storage. See 1.10 + * http://dev.w3.org/html5/webstorage/#the-storage-event 1.11 + * for more information. 1.12 + * 1.13 + * Event sent to a window when a storage area changes. 1.14 + */ 1.15 +interface Storage; 1.16 + 1.17 +[Constructor(DOMString type, optional StorageEventInit eventInitDict), HeaderFile="GeneratedEventClasses.h"] 1.18 +interface StorageEvent : Event 1.19 +{ 1.20 + readonly attribute DOMString? key; 1.21 + readonly attribute DOMString? oldValue; 1.22 + readonly attribute DOMString? newValue; 1.23 + readonly attribute DOMString? url; 1.24 + readonly attribute Storage? storageArea; 1.25 + 1.26 + // initStorageEvent is a Gecko specific deprecated method. 1.27 + [Throws] 1.28 + void initStorageEvent(DOMString type, 1.29 + boolean canBubble, 1.30 + boolean cancelable, 1.31 + DOMString? key, 1.32 + DOMString? oldValue, 1.33 + DOMString? newValue, 1.34 + DOMString? url, 1.35 + Storage? storageArea); 1.36 +}; 1.37 + 1.38 +dictionary StorageEventInit : EventInit 1.39 +{ 1.40 + DOMString? key = null; 1.41 + DOMString? oldValue = null; 1.42 + DOMString? newValue = null; 1.43 + DOMString url = ""; 1.44 + Storage? storageArea = null; 1.45 +};