mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-15 14:25:52 +00:00
Merge mozilla-central to mozilla-inbound
This commit is contained in:
commit
e4c2fc223c
@ -60,7 +60,6 @@ CPPSRCS = \
|
||||
nsDOMScrollAreaEvent.cpp \
|
||||
nsDOMTransitionEvent.cpp \
|
||||
nsDOMAnimationEvent.cpp \
|
||||
nsDOMSettingsEvent.cpp \
|
||||
nsDOMTouchEvent.cpp \
|
||||
nsDOMCompositionEvent.cpp \
|
||||
$(NULL)
|
||||
|
@ -1,77 +0,0 @@
|
||||
/* -*- Mode: C++; 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/. */
|
||||
|
||||
#include "nsDOMClassInfoID.h"
|
||||
#include "nsDOMSettingsEvent.h"
|
||||
#include "DictionaryHelpers.h"
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(nsDOMMozSettingsEvent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(nsDOMMozSettingsEvent, nsDOMEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_NSCOMPTR(mSettingValue)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(nsDOMMozSettingsEvent, nsDOMEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSCOMPTR(mSettingValue)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
|
||||
|
||||
DOMCI_DATA(MozSettingsEvent, nsDOMMozSettingsEvent)
|
||||
|
||||
NS_INTERFACE_MAP_BEGIN(nsDOMMozSettingsEvent)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMMozSettingsEvent)
|
||||
NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(MozSettingsEvent)
|
||||
NS_INTERFACE_MAP_END_INHERITING(nsDOMEvent)
|
||||
|
||||
NS_IMPL_ADDREF_INHERITED(nsDOMMozSettingsEvent, nsDOMEvent)
|
||||
NS_IMPL_RELEASE_INHERITED(nsDOMMozSettingsEvent, nsDOMEvent)
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDOMMozSettingsEvent::GetSettingName(nsAString & aSettingName)
|
||||
{
|
||||
aSettingName = mSettingName;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDOMMozSettingsEvent::GetSettingValue(nsIVariant** aSettingValue)
|
||||
{
|
||||
NS_IF_ADDREF(*aSettingValue = mSettingValue);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDOMMozSettingsEvent::InitMozSettingsEvent(const nsAString& aType,
|
||||
bool aCanBubble,
|
||||
bool aCancelable,
|
||||
const nsAString &aSettingName,
|
||||
nsIVariant *aSettingValue)
|
||||
{
|
||||
nsresult rv = nsDOMEvent::InitEvent(aType, aCanBubble, aCancelable);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
mSettingName = aSettingName;
|
||||
mSettingValue = aSettingValue;
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsDOMMozSettingsEvent::InitFromCtor(const nsAString& aType,
|
||||
JSContext* aCx, jsval* aVal)
|
||||
{
|
||||
mozilla::dom::MozSettingsEventInit d;
|
||||
nsresult rv = d.Init(aCx, aVal);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
return InitMozSettingsEvent(aType, d.bubbles, d.cancelable, d.settingName, d.settingValue);
|
||||
}
|
||||
|
||||
nsresult
|
||||
NS_NewDOMMozSettingsEvent(nsIDOMEvent** aInstancePtrResult,
|
||||
nsPresContext* aPresContext,
|
||||
nsEvent* aEvent)
|
||||
{
|
||||
nsDOMMozSettingsEvent* e = new nsDOMMozSettingsEvent(aPresContext, aEvent);
|
||||
return CallQueryInterface(e, aInstancePtrResult);
|
||||
}
|
@ -1,33 +0,0 @@
|
||||
/* -*- Mode: C++; 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/. */
|
||||
|
||||
#ifndef nsDOMSettingsEvent_h__
|
||||
#define nsDOMSettingsEvent_h__
|
||||
|
||||
#include "nsIDOMSettingsManager.h"
|
||||
#include "nsDOMEvent.h"
|
||||
|
||||
class nsDOMMozSettingsEvent : public nsDOMEvent,
|
||||
public nsIDOMMozSettingsEvent
|
||||
{
|
||||
public:
|
||||
nsDOMMozSettingsEvent(nsPresContext* aPresContext, nsEvent* aEvent)
|
||||
: nsDOMEvent(aPresContext, aEvent) {}
|
||||
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(nsDOMMozSettingsEvent, nsDOMEvent)
|
||||
// Forward to base class
|
||||
NS_FORWARD_TO_NSDOMEVENT
|
||||
|
||||
NS_DECL_NSIDOMMOZSETTINGSEVENT
|
||||
|
||||
virtual nsresult InitFromCtor(const nsAString& aType,
|
||||
JSContext* aCx, jsval* aVal);
|
||||
private:
|
||||
nsString mSettingName;
|
||||
nsCOMPtr<nsIVariant> mSettingValue;
|
||||
};
|
||||
|
||||
#endif // nsDOMSettingsEvent_h__
|
@ -866,8 +866,7 @@ nsEventDispatcher::CreateEvent(nsPresContext* aPresContext,
|
||||
if (aEventType.LowerCaseEqualsLiteral("mozsmsevent"))
|
||||
return NS_NewDOMSmsEvent(aDOMEvent, aPresContext, nullptr);
|
||||
if (aEventType.LowerCaseEqualsLiteral("storageevent")) {
|
||||
NS_ADDREF(*aDOMEvent = static_cast<nsDOMEvent*>(new nsDOMStorageEvent()));
|
||||
return NS_OK;
|
||||
return NS_NewDOMStorageEvent(aDOMEvent, aPresContext, nsnull);
|
||||
}
|
||||
|
||||
|
||||
|
@ -1371,8 +1371,6 @@ static nsDOMClassInfoData sClassInfoData[] = {
|
||||
nsIXPCScriptable::WANT_NEWENUMERATE)
|
||||
NS_DEFINE_CLASSINFO_DATA(StorageItem, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
NS_DEFINE_CLASSINFO_DATA(StorageEvent, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
|
||||
NS_DEFINE_CLASSINFO_DATA(DOMParser, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
@ -1642,8 +1640,6 @@ static nsDOMClassInfoData sClassInfoData[] = {
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
NS_DEFINE_CLASSINFO_DATA(MutationRecord, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
NS_DEFINE_CLASSINFO_DATA(MozSettingsEvent, nsDOMGenericSH,
|
||||
DOM_DEFAULT_SCRIPTABLE_FLAGS)
|
||||
|
||||
#ifdef MOZ_B2G_RIL
|
||||
NS_DEFINE_CLASSINFO_DATA(MozWifiStatusChangeEvent, nsDOMGenericSH,
|
||||
@ -1737,7 +1733,6 @@ static const nsContractIDMapData kConstructorMap[] =
|
||||
}
|
||||
|
||||
NS_DEFINE_EVENT_CTOR(Event)
|
||||
NS_DEFINE_EVENT_CTOR(MozSettingsEvent)
|
||||
NS_DEFINE_EVENT_CTOR(UIEvent)
|
||||
NS_DEFINE_EVENT_CTOR(MouseEvent)
|
||||
#ifdef MOZ_B2G_RIL
|
||||
@ -1751,13 +1746,6 @@ NS_DEFINE_EVENT_CTOR(MozWifiConnectionInfoEvent)
|
||||
#include "GeneratedEvents.h"
|
||||
#undef MOZ_GENERATED_EVENT_LIST
|
||||
|
||||
nsresult
|
||||
NS_DOMStorageEventCtor(nsISupports** aInstancePtrResult)
|
||||
{
|
||||
nsDOMStorageEvent* e = new nsDOMStorageEvent();
|
||||
return CallQueryInterface(e, aInstancePtrResult);
|
||||
}
|
||||
|
||||
nsresult
|
||||
NS_XMLHttpRequestCtor(nsISupports** aInstancePtrResult)
|
||||
{
|
||||
@ -1783,10 +1771,8 @@ static const nsConstructorFuncMapData kConstructorFuncMap[] =
|
||||
NS_DEFINE_CONSTRUCTOR_FUNC_DATA(File, nsDOMFileFile::NewFile)
|
||||
NS_DEFINE_CONSTRUCTOR_FUNC_DATA(MozBlobBuilder, NS_NewBlobBuilder)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(Event)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(MozSettingsEvent)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(UIEvent)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(MouseEvent)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(StorageEvent)
|
||||
#ifdef MOZ_B2G_RIL
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(MozWifiStatusChangeEvent)
|
||||
NS_DEFINE_EVENT_CONSTRUCTOR_FUNC_DATA(MozWifiConnectionInfoEvent)
|
||||
@ -3934,11 +3920,6 @@ nsDOMClassInfo::Init()
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMToString)
|
||||
DOM_CLASSINFO_MAP_END
|
||||
|
||||
DOM_CLASSINFO_MAP_BEGIN(StorageEvent, nsIDOMStorageEvent)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMStorageEvent)
|
||||
DOM_CLASSINFO_EVENT_MAP_ENTRIES
|
||||
DOM_CLASSINFO_MAP_END
|
||||
|
||||
DOM_CLASSINFO_MAP_BEGIN_NO_CLASS_IF(DOMParser, nsIDOMParser)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMParser)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMParserJS)
|
||||
@ -4411,11 +4392,6 @@ nsDOMClassInfo::Init()
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMMutationRecord)
|
||||
DOM_CLASSINFO_MAP_END
|
||||
|
||||
DOM_CLASSINFO_MAP_BEGIN(MozSettingsEvent, nsIDOMMozSettingsEvent)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMMozSettingsEvent)
|
||||
DOM_CLASSINFO_EVENT_MAP_ENTRIES
|
||||
DOM_CLASSINFO_MAP_END
|
||||
|
||||
#ifdef MOZ_B2G_RIL
|
||||
DOM_CLASSINFO_MAP_BEGIN(MozWifiStatusChangeEvent, nsIDOMMozWifiStatusChangeEvent)
|
||||
DOM_CLASSINFO_MAP_ENTRY(nsIDOMMozWifiStatusChangeEvent)
|
||||
|
@ -341,7 +341,6 @@ DOMCI_CLASS(XPathResult)
|
||||
DOMCI_CLASS(StorageObsolete)
|
||||
DOMCI_CLASS(Storage)
|
||||
DOMCI_CLASS(StorageItem)
|
||||
DOMCI_CLASS(StorageEvent)
|
||||
|
||||
// DOMParser, XMLSerializer
|
||||
DOMCI_CLASS(DOMParser)
|
||||
@ -507,8 +506,6 @@ DOMCI_CLASS(MediaQueryList)
|
||||
DOMCI_CLASS(MutationObserver)
|
||||
DOMCI_CLASS(MutationRecord)
|
||||
|
||||
DOMCI_CLASS(MozSettingsEvent)
|
||||
|
||||
#ifdef MOZ_B2G_RIL
|
||||
DOMCI_CLASS(MozWifiStatusChangeEvent)
|
||||
DOMCI_CLASS(MozWifiConnectionInfoEvent)
|
||||
|
@ -197,7 +197,7 @@
|
||||
#include "nsFrameLoader.h"
|
||||
#include "nsISupportsPrimitives.h"
|
||||
#include "nsXPCOMCID.h"
|
||||
|
||||
#include "GeneratedEvents.h"
|
||||
#include "mozilla/FunctionTimer.h"
|
||||
#include "mozIThirdPartyUtil.h"
|
||||
|
||||
@ -9016,7 +9016,8 @@ nsGlobalWindow::CloneStorageEvent(const nsAString& aType,
|
||||
aEvent->GetUrl(url);
|
||||
aEvent->GetStorageArea(getter_AddRefs(storageArea));
|
||||
|
||||
aEvent = new nsDOMStorageEvent();
|
||||
NS_NewDOMStorageEvent(getter_AddRefs(domEvent), nsnull, nsnull);
|
||||
aEvent = do_QueryInterface(domEvent);
|
||||
return aEvent->InitStorageEvent(aType, canBubble, cancelable,
|
||||
key, oldValue, newValue,
|
||||
url, storageArea);
|
||||
|
@ -16,6 +16,7 @@ GRE_MODULE = 1
|
||||
XPIDLSRCS = \
|
||||
nsIDOMSettingsManager.idl \
|
||||
nsISettingsService.idl \
|
||||
nsIDOMMozSettingsEvent.idl \
|
||||
$(NULL)
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
25
dom/interfaces/settings/nsIDOMMozSettingsEvent.idl
Normal file
25
dom/interfaces/settings/nsIDOMMozSettingsEvent.idl
Normal file
@ -0,0 +1,25 @@
|
||||
/* 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 "nsIDOMEvent.idl"
|
||||
interface nsIVariant;
|
||||
|
||||
[scriptable, builtinclass, uuid(5e304193-af49-4546-8329-bf7c9159ed98)]
|
||||
interface nsIDOMMozSettingsEvent : nsIDOMEvent
|
||||
{
|
||||
readonly attribute DOMString settingName;
|
||||
readonly attribute nsIVariant settingValue;
|
||||
|
||||
[noscript] void initMozSettingsEvent(in DOMString aType,
|
||||
in boolean aCanBubble,
|
||||
in boolean aCancelable,
|
||||
in DOMString aSettingName,
|
||||
in nsIVariant aSettingValue);
|
||||
};
|
||||
|
||||
dictionary MozSettingsEventInit : EventInit
|
||||
{
|
||||
DOMString settingName;
|
||||
nsIVariant settingValue;
|
||||
};
|
@ -4,7 +4,6 @@
|
||||
|
||||
#include "domstubs.idl"
|
||||
#include "nsIDOMEventTarget.idl"
|
||||
#include "nsIDOMEvent.idl"
|
||||
|
||||
interface nsIDOMDOMRequest;
|
||||
interface nsIVariant;
|
||||
@ -31,22 +30,3 @@ interface nsIDOMSettingsManager : nsISupports
|
||||
|
||||
attribute nsIDOMEventListener onsettingchange;
|
||||
};
|
||||
|
||||
[scriptable, builtinclass, uuid(5e304193-af49-4546-8329-bf7c9159ed98)]
|
||||
interface nsIDOMMozSettingsEvent : nsIDOMEvent
|
||||
{
|
||||
readonly attribute DOMString settingName;
|
||||
readonly attribute nsIVariant settingValue;
|
||||
|
||||
[noscript] void initMozSettingsEvent(in DOMString aType,
|
||||
in boolean aCanBubble,
|
||||
in boolean aCancelable,
|
||||
in DOMString aSettingName,
|
||||
in nsIVariant aSettingValue);
|
||||
};
|
||||
|
||||
dictionary MozSettingsEventInit : EventInit
|
||||
{
|
||||
DOMString settingName;
|
||||
nsIVariant settingValue;
|
||||
};
|
||||
|
@ -38,6 +38,7 @@ using mozilla::dom::ContentChild;
|
||||
#include "nsThreadUtils.h"
|
||||
#include "mozilla/Telemetry.h"
|
||||
#include "DictionaryHelpers.h"
|
||||
#include "GeneratedEvents.h"
|
||||
|
||||
// calls FlushAndDeleteTemporaryTables(false)
|
||||
#define NS_DOMSTORAGE_FLUSH_TIMER_TOPIC "domstorage-flush-timer"
|
||||
@ -1893,7 +1894,9 @@ nsDOMStorage2::BroadcastChangeNotification(const nsSubstring &aKey,
|
||||
const nsSubstring &aNewValue)
|
||||
{
|
||||
nsresult rv;
|
||||
nsCOMPtr<nsIDOMStorageEvent> event = new nsDOMStorageEvent();
|
||||
nsCOMPtr<nsIDOMEvent> domEvent;
|
||||
NS_NewDOMStorageEvent(getter_AddRefs(domEvent), nsnull, nsnull);
|
||||
nsCOMPtr<nsIDOMStorageEvent> event = do_QueryInterface(domEvent);
|
||||
rv = event->InitStorageEvent(NS_LITERAL_STRING("storage"),
|
||||
false,
|
||||
false,
|
||||
@ -2079,97 +2082,3 @@ nsDOMStorageItem::ToString(nsAString& aStr)
|
||||
return GetValue(aStr);
|
||||
}
|
||||
|
||||
// Cycle collection implementation for nsDOMStorageEvent
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(nsDOMStorageEvent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(nsDOMStorageEvent, nsDOMEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_NSCOMPTR(mStorageArea)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(nsDOMStorageEvent, nsDOMEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSCOMPTR(mStorageArea)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
|
||||
|
||||
NS_IMPL_ADDREF_INHERITED(nsDOMStorageEvent, nsDOMEvent)
|
||||
NS_IMPL_RELEASE_INHERITED(nsDOMStorageEvent, nsDOMEvent)
|
||||
|
||||
DOMCI_DATA(StorageEvent, nsDOMStorageEvent)
|
||||
|
||||
// QueryInterface implementation for nsDOMStorageEvent
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(nsDOMStorageEvent)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIDOMStorageEvent)
|
||||
NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(StorageEvent)
|
||||
NS_INTERFACE_MAP_END_INHERITING(nsDOMEvent)
|
||||
|
||||
|
||||
/* readonly attribute DOMString key; */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::GetKey(nsAString & aKey)
|
||||
{
|
||||
aKey = mKey;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
/* readonly attribute DOMString oldValue; */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::GetOldValue(nsAString & aOldValue)
|
||||
{
|
||||
aOldValue = mOldValue;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
/* readonly attribute DOMString newValue; */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::GetNewValue(nsAString & aNewValue)
|
||||
{
|
||||
aNewValue = mNewValue;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
/* readonly attribute DOMString url; */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::GetUrl(nsAString & aUrl)
|
||||
{
|
||||
aUrl = mUrl;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
/* readonly attribute nsIDOMStorage storageArea; */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::GetStorageArea(nsIDOMStorage * *aStorageArea)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aStorageArea);
|
||||
|
||||
NS_IF_ADDREF(*aStorageArea = mStorageArea);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
/* void initStorageEvent (in DOMString typeArg, in boolean canBubbleArg, in boolean cancelableArg, in DOMString keyArg, in DOMString oldValueArg, in DOMString newValueArg, in DOMString urlArg, in nsIDOMStorage storageAreaArg); */
|
||||
NS_IMETHODIMP nsDOMStorageEvent::InitStorageEvent(const nsAString & typeArg,
|
||||
bool canBubbleArg,
|
||||
bool cancelableArg,
|
||||
const nsAString & keyArg,
|
||||
const nsAString & oldValueArg,
|
||||
const nsAString & newValueArg,
|
||||
const nsAString & urlArg,
|
||||
nsIDOMStorage *storageAreaArg)
|
||||
{
|
||||
nsresult rv;
|
||||
|
||||
rv = InitEvent(typeArg, canBubbleArg, cancelableArg);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
mKey = keyArg;
|
||||
mOldValue = oldValueArg;
|
||||
mNewValue = newValueArg;
|
||||
mUrl = urlArg;
|
||||
mStorageArea = storageAreaArg;
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsDOMStorageEvent::InitFromCtor(const nsAString& aType,
|
||||
JSContext* aCx, jsval* aVal)
|
||||
{
|
||||
mozilla::dom::StorageEventInit d;
|
||||
nsresult rv = d.Init(aCx, aVal);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
return InitStorageEvent(aType, d.bubbles, d.cancelable, d.key, d.oldValue,
|
||||
d.newValue, d.url, d.storageArea);
|
||||
}
|
||||
|
@ -500,37 +500,6 @@ protected:
|
||||
nsRefPtr<DOMStorageBase> mStorage;
|
||||
};
|
||||
|
||||
class nsDOMStorageEvent : public nsDOMEvent,
|
||||
public nsIDOMStorageEvent
|
||||
{
|
||||
public:
|
||||
nsDOMStorageEvent()
|
||||
: nsDOMEvent(nullptr, nullptr)
|
||||
{
|
||||
}
|
||||
|
||||
virtual ~nsDOMStorageEvent()
|
||||
{
|
||||
}
|
||||
|
||||
nsresult Init();
|
||||
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(nsDOMStorageEvent, nsDOMEvent)
|
||||
|
||||
NS_DECL_NSIDOMSTORAGEEVENT
|
||||
NS_FORWARD_NSIDOMEVENT(nsDOMEvent::)
|
||||
|
||||
virtual nsresult InitFromCtor(const nsAString& aType,
|
||||
JSContext* aCx, jsval* aVal);
|
||||
protected:
|
||||
nsString mKey;
|
||||
nsString mOldValue;
|
||||
nsString mNewValue;
|
||||
nsString mUrl;
|
||||
nsCOMPtr<nsIDOMStorage> mStorageArea;
|
||||
};
|
||||
|
||||
nsresult
|
||||
NS_NewDOMStorage2(nsISupports* aOuter, REFNSIID aIID, void** aResult);
|
||||
|
||||
|
@ -9,10 +9,8 @@ dictionaries = [
|
||||
[ 'MouseEventInit', 'nsIDOMMouseEvent.idl' ],
|
||||
[ 'IDBObjectStoreParameters', 'nsIIDBDatabase.idl' ],
|
||||
[ 'IDBIndexParameters', 'nsIIDBObjectStore.idl' ],
|
||||
[ 'StorageEventInit', 'nsIDOMStorageEvent.idl' ],
|
||||
[ 'BlobPropertyBag', 'nsIDOMFile.idl' ],
|
||||
[ 'MutationObserverInit', 'nsIDOMMutationObserver.idl' ],
|
||||
[ 'SettingsEventInit', 'nsIDOMSettingsManager.idl' ],
|
||||
[ 'WifiConnectionInfoEventInit', 'nsIWifiEventInits.idl' ],
|
||||
[ 'WifiStatusChangeEventInit', 'nsIWifiEventInits.idl' ],
|
||||
[ 'GeoPositionOptions', 'nsIDOMGeoGeolocation.idl' ],
|
||||
|
@ -8,7 +8,9 @@
|
||||
<name>Init dictionary for the event constructor. """
|
||||
|
||||
simple_events = [
|
||||
'StorageEvent',
|
||||
'DeviceProximityEvent',
|
||||
'MozSettingsEvent',
|
||||
'UserProximityEvent',
|
||||
'CustomEvent',
|
||||
'PageTransitionEvent',
|
||||
|
@ -582,7 +582,6 @@ MarionetteDriverActor.prototype = {
|
||||
else {
|
||||
this.scriptTimeout = timeout;
|
||||
this.sendAsync("setScriptTimeout", {value: timeout});
|
||||
this.sendOk();
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -377,6 +377,7 @@ function executeScript(msg, directInject) {
|
||||
*/
|
||||
function setScriptTimeout(msg) {
|
||||
marionetteTimeout = msg.json.value;
|
||||
sendOk();
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user