Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes
nsActivePlugin Struct Reference

#include <nsPluginHostImpl.h>

Collaboration diagram for nsActivePlugin:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 nsActivePlugin (nsPluginTag *aPluginTag, nsIPluginInstance *aInstance, const char *url, PRBool aDefaultPlugin, nsIPluginInstancePeer *peer)
 ~nsActivePlugin ()
void setStopped (PRBool stopped)

Public Attributes

nsActivePluginmNext
char * mURL
nsIPluginInstancePeermPeer
nsPluginTagmPluginTag
nsIPluginInstancemInstance
PRTime mllStopTime
PRPackedBool mStopped
PRPackedBool mDefaultPlugin
PRPackedBool mXPConnected
nsCOMPtr< nsISupportsArraymStreams

Detailed Description

Definition at line 128 of file nsPluginHostImpl.h.


Constructor & Destructor Documentation

nsActivePlugin::nsActivePlugin ( nsPluginTag aPluginTag,
nsIPluginInstance aInstance,
const char *  url,
PRBool  aDefaultPlugin,
nsIPluginInstancePeer peer 
)

Definition at line 365 of file nsPluginHostImpl.cpp.

{
  mNext = nsnull;
  mPeer = nsnull;
  mPluginTag = aPluginTag;

  mURL = PL_strdup(url);
  mInstance = aInstance;
  if(aInstance && peer)
  {
    mPeer = peer;
    NS_ADDREF(mPeer);
    NS_ADDREF(aInstance);
  }
  mXPConnected = PR_FALSE;
  mDefaultPlugin = aDefaultPlugin;
  mStopped = PR_FALSE;
  mllStopTime = LL_ZERO;
}

Here is the call graph for this function:

Definition at line 391 of file nsPluginHostImpl.cpp.

{
  mPluginTag = nsnull;
  if(mInstance != nsnull)
  {
    if(mPeer)
    {
      nsresult rv = NS_OK;
      nsCOMPtr<nsPIPluginInstancePeer> peer(do_QueryInterface(mPeer));
      nsCOMPtr<nsIPluginInstanceOwner> owner;
      rv = peer->GetOwner(getter_AddRefs(owner));
      if (owner)
        owner->SetInstance(nsnull);
    }

    // now check for cached plugins because they haven't had nsIPluginInstance::Destroy()
    // called yet. For non-cached plugins, nsIPluginInstance::Destroy() is called
    // in either nsObjectFrame::Destroy() or nsActivePluginList::stopRunning()
    PRBool doCache = PR_TRUE;
    mInstance->GetValue(nsPluginInstanceVariable_DoCacheBool, (void *) &doCache);
    if (doCache)
      mInstance->Destroy();

    NS_RELEASE(mInstance);
    NS_RELEASE(mPeer);
  }
  PL_strfree(mURL);
}

Here is the call graph for this function:


Member Function Documentation

Definition at line 422 of file nsPluginHostImpl.cpp.

{
  mStopped = stopped;
  if(mStopped) // plugin instance is told to stop
    mllStopTime = PR_Now();
  else
    mllStopTime = LL_ZERO;
}

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 137 of file nsPluginHostImpl.h.

Definition at line 134 of file nsPluginHostImpl.h.

Definition at line 135 of file nsPluginHostImpl.h.

Definition at line 130 of file nsPluginHostImpl.h.

Definition at line 132 of file nsPluginHostImpl.h.

Definition at line 133 of file nsPluginHostImpl.h.

Definition at line 136 of file nsPluginHostImpl.h.

Definition at line 140 of file nsPluginHostImpl.h.

Definition at line 131 of file nsPluginHostImpl.h.

Definition at line 138 of file nsPluginHostImpl.h.


The documentation for this struct was generated from the following files: