зеркало из https://github.com/mozilla/gecko-dev.git
Bug 870466 - Remove initProgressEvent from workers; r=bent
This commit is contained in:
Родитель
94aefffcb2
Коммит
0c1f17bb70
|
@ -801,7 +801,6 @@ class ProgressEvent : public Event
|
|||
{
|
||||
static JSClass sClass;
|
||||
static const JSPropertySpec sProperties[];
|
||||
static const JSFunctionSpec sFunctions[];
|
||||
|
||||
public:
|
||||
static JSClass*
|
||||
|
@ -814,7 +813,7 @@ public:
|
|||
InitClass(JSContext* aCx, JSObject* aObj, JSObject* aParentProto)
|
||||
{
|
||||
return JS_InitClass(aCx, aObj, aParentProto, &sClass, Construct, 0,
|
||||
sProperties, sFunctions, NULL, NULL);
|
||||
sProperties, NULL, NULL, NULL);
|
||||
}
|
||||
|
||||
static JSObject*
|
||||
|
@ -920,33 +919,6 @@ private:
|
|||
aVp.set(JS_GetReservedSlot(aObj, slot));
|
||||
return true;
|
||||
}
|
||||
|
||||
static JSBool
|
||||
InitProgressEvent(JSContext* aCx, unsigned aArgc, jsval* aVp)
|
||||
{
|
||||
JS::Rooted<JSObject*> obj(aCx, JS_THIS_OBJECT(aCx, aVp));
|
||||
if (!obj) {
|
||||
return false;
|
||||
}
|
||||
|
||||
ProgressEvent* event = GetInstancePrivate(aCx, obj, sFunctions[0].name);
|
||||
if (!event) {
|
||||
return false;
|
||||
}
|
||||
|
||||
JS::Rooted<JSString*> type(aCx);
|
||||
JSBool bubbles, cancelable, lengthComputable;
|
||||
double loaded, total;
|
||||
if (!JS_ConvertArguments(aCx, aArgc, JS_ARGV(aCx, aVp), "Sbbbdd", type.address(),
|
||||
&bubbles, &cancelable, &lengthComputable, &loaded,
|
||||
&total)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
InitProgressEventCommon(obj, event, type, bubbles, cancelable,
|
||||
lengthComputable, loaded, total, false);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
JSClass ProgressEvent::sClass = {
|
||||
|
@ -966,11 +938,6 @@ const JSPropertySpec ProgressEvent::sProperties[] = {
|
|||
{ 0, 0, 0, JSOP_NULLWRAPPER, JSOP_NULLWRAPPER }
|
||||
};
|
||||
|
||||
const JSFunctionSpec ProgressEvent::sFunctions[] = {
|
||||
JS_FN("initProgressEvent", InitProgressEvent, 6, FUNCTION_FLAGS),
|
||||
JS_FS_END
|
||||
};
|
||||
|
||||
Event*
|
||||
Event::GetPrivate(JSObject* aObj)
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче