Closed Bug 394086 Opened 17 years ago Closed 17 years ago

Stop some special casing for applets in nsDOMClassInfo

Categories

(Core Graveyard :: Plug-ins, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jst, Assigned: jst)

References

Details

Attachments

(4 files)

This is part of bug 393928. Right now we've got a separate scriptable helper for applets, but in a world where the java plugin is scriptable through NPRuntime we need to not only ask for a scriptable applet object through LiveConnect, but also through the normal paths we go through for non-java plugins.
Assignee: nobody → jst
Status: NEW → ASSIGNED
Attachment #278673 - Flags: review?(cbiesinger)
+        sNPRuntimeJSClassName = JS_GET_CLASS(cx, plugin_obj)->name;

Since that's really a constant, perhaps plugin should expose that in a header somewhere?

+  nsCOMPtr<nsIPluginInstanceInternal> plugin_internal =
+    do_QueryInterface(pi);
+
+  nsCOMPtr<nsIJVMPluginInstance> javaPluginInstance =
+    do_QueryInterface(pi);

Consistent naming would be nice

Attachment #278673 - Flags: superreview+
Attachment #278673 - Flags: review?(cbiesinger)
Attachment #278673 - Flags: review+
Thanks cbiesinger!

For the record, The line:

+        sNPRuntimeJSClassName = JS_GET_CLASS(cx, plugin_obj)->name;

in nsHTMLPluginObjElementSH::GetPluginJSObject() is missing a '*' before plugin_obj. Last minute goofup...
Flags: blocking1.9+
Fix checked in.
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
mozilla/dom/src/base/nsDOMClassInfo.cpp: In member function 'virtual nsresult nsHTMLPluginObjElementSH::NewResolve(nsIXPConnectWrappedNative*, JSContext*, JSObject*, jsval, PRUint32, JSObject**, PRBool*)':
mozilla/dom/src/base/nsDOMClassInfo.cpp:8987: error: 'nsIJVMPluginInstance' was not declared in this scope
mozilla/dom/src/base/nsDOMClassInfo.cpp:8987: error: template argument 1 is invalid
mozilla/dom/src/base/nsDOMClassInfo.cpp:8987: error: invalid type in declaration before '=' token
mozilla/dom/src/base/nsDOMClassInfo.cpp:8988: error: cannot convert 'nsQueryInterface' to 'int' in initialization

Thunderbird bustage from this patch.
This is needed for apps that don't define OJI.
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: