FreeWRL/FreeX3D  3.0.0
nsIPluginInstance Interface Reference
Inheritance diagram for nsIPluginInstance:

Public Member Functions

void initialize (in nsIPluginInstanceOwner aOwner, in string aMIMEType)
 Initializes a newly created plugin instance. More...
 
void start ()
 Called to instruct the plugin instance to start. More...
 
void stop ()
 Called to instruct the plugin instance to stop, thereby suspending its state. More...
 
void setWindow (in nsPluginWindowPtr aWindow)
 Called when the window containing the plugin instance changes. More...
 
void newStreamToPlugin (out nsIPluginStreamListener aListener)
 Called to tell the plugin that the initial src/data stream is ready. More...
 
void newStreamFromPlugin (in string aType, in string aTarget, out nsIOutputStream aResult)
 This operation is called by the plugin instance when it wishes to send a stream of data to the browser. More...
 
void print (in nsPluginPrintPtr aPlatformPrint)
 Called to instruct the plugin instance to print itself to a printer. More...
 
void getValue (in nsPluginInstanceVariable aVariable, in voidPtr aValue)
 Returns the value of a variable associated with the plugin instance. More...
 
void handleEvent (in nsPluginEventPtr aEvent, out boolean aHandled)
 Handles an event. More...
 
void invalidateRect (in nsPluginRectPtr aRect)
 Corresponds to NPN_InvalidateRect.
 
void invalidateRegion (in nsPluginRegion aRegion)
 Corresponds to NPN_InvalidateRegion.
 
void forceRedraw ()
 Corresponds to NPN_ForceRedraw.
 
void getMIMEType ([const, shared] out string aValue)
 Returns the MIME type of the plugin instance. More...
 
void showStatus (in string aMessage)
 This operation causes status information to be displayed on the window associated with the plugin instance. More...
 
void invalidateOwner ()
 Drop our reference to our owner.
 
JSObjectPtr GetJSObject (in JSContextPtr cx)
 
void pushPopupsEnabledState (in boolean aEnabled)
 
void popPopupsEnabledState ()
 
void defineJavaProperties ()
 

Data Fields

readonly attribute JSContextPtr JSContext
 Get the JavaScript context to this plugin instance. More...
 
attribute nsIPluginInstanceOwner owner
 
readonly attribute AString formValue
 
readonly attribute PRUint16 pluginAPIVersion
 

Detailed Description

Definition at line 57 of file nsIPluginInstance.idl.

Member Function Documentation

void nsIPluginInstance::getMIMEType ( [const, shared] out string  aValue)

Returns the MIME type of the plugin instance.

(Corresponds to NPP_New's MIMEType argument.)

Parameters
aMIMEType- resulting MIME type
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::getValue ( in nsPluginInstanceVariable  aVariable,
in voidPtr  aValue 
)

Returns the value of a variable associated with the plugin instance.

Parameters
aVariable- the plugin instance variable to get
aValue- the address of where to store the resulting value
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::handleEvent ( in nsPluginEventPtr  aEvent,
out boolean  aHandled 
)

Handles an event.

Note that for Unix and Mac the nsPluginEvent structure is different from the old NPEvent structure – it's no longer the native event record, but is instead a struct. This was done for future extensibility, and so that the Mac could receive the window argument too. For Windows and OS2, it's always been a struct, so there's no change for them.

(Corresponds to NPP_HandleEvent.)

Parameters
aEvent- the event to be handled
aHandled- set to PR_TRUE if event was handled
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::initialize ( in nsIPluginInstanceOwner  aOwner,
in string  aMIMEType 
)

Initializes a newly created plugin instance.

Parameters
aOwner- the plugin instance owner
aMime- the mime type for the instance
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::newStreamFromPlugin ( in string  aType,
in string  aTarget,
out nsIOutputStream  aResult 
)

This operation is called by the plugin instance when it wishes to send a stream of data to the browser.

It constructs a new output stream to which the plugin may send the data. When complete, the Close and Release methods should be called on the output stream.

(Corresponds to NPN_NewStream.)

Parameters
aType- MIME type of the stream to create
aTarget- the target window name to receive the data
aResult- the resulting output stream
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::newStreamToPlugin ( out nsIPluginStreamListener  aListener)

Called to tell the plugin that the initial src/data stream is ready.

Expects the plugin to return a nsIPluginStreamListener.

(Corresponds to NPP_NewStream.)

Parameters
aListener- listener the browser will use to give the plugin the data
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::print ( in nsPluginPrintPtr  aPlatformPrint)

Called to instruct the plugin instance to print itself to a printer.

(Corresponds to NPP_Print.)

Parameters
aPlatformPrint- platform-specific printing information
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::setWindow ( in nsPluginWindowPtr  aWindow)

Called when the window containing the plugin instance changes.

(Corresponds to NPP_SetWindow.)

Parameters
aWindow- the plugin window structure
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::showStatus ( in string  aMessage)

This operation causes status information to be displayed on the window associated with the plugin instance.

(Corresponds to NPN_Status.)

Parameters
aMessage- the status message to display
Returns
- NS_OK if this operation was successful
void nsIPluginInstance::start ( )

Called to instruct the plugin instance to start.

This will be called after the plugin is first created and initialized, and may be called after the plugin is stopped (via the Stop method) if the plugin instance is returned to in the browser window's history.

Returns
- NS_OK if this operation was successful
void nsIPluginInstance::stop ( )

Called to instruct the plugin instance to stop, thereby suspending its state.

This method will be called whenever the browser window goes on to display another page and the page containing the plugin goes into the window's history list.

Returns
- NS_OK if this operation was successful

Field Documentation

readonly attribute JSContextPtr nsIPluginInstance::JSContext

Get the JavaScript context to this plugin instance.

Parameters
aJSContext- the resulting JavaScript context
Returns
- NS_OK if this operation was successful

Definition at line 192 of file nsIPluginInstance.idl.


The documentation for this interface was generated from the following file: