Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes
IELocation Class Reference
Inheritance diagram for IELocation:
Inheritance graph
[legend]
Collaboration diagram for IELocation:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 IELocation ()
HRESULT Init (PluginInstanceData *pData)
virtual nsresult GetDOMLocation (nsIDOMLocation **aLocation)
virtual HRESULT STDMETHODCALLTYPE put_href (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_href (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_protocol (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_protocol (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_host (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_host (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_hostname (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_hostname (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_port (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_port (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_pathname (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_pathname (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_search (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_search (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE put_hash (BSTR v)
virtual HRESULT STDMETHODCALLTYPE get_hash (BSTR *p)
virtual HRESULT STDMETHODCALLTYPE reload (VARIANT_BOOL flag)
virtual HRESULT STDMETHODCALLTYPE replace (BSTR bstr)
virtual HRESULT STDMETHODCALLTYPE assign (BSTR bstr)
virtual HRESULT STDMETHODCALLTYPE toString (BSTR *string)

Public Attributes

PluginInstanceDatamData
nsCOMPtr< nsIDOMLocationmDOMLocation

Detailed Description

Definition at line 145 of file XPCDocument.cpp.


Constructor & Destructor Documentation

IELocation::IELocation ( ) [inline]

Definition at line 158 of file XPCDocument.cpp.

                 : mData(NULL)
    {
    }

Member Function Documentation

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::assign ( BSTR  bstr) [inline, virtual, inherited]

Definition at line 164 of file IHTMLLocationImpl.h.

    {
        nsCOMPtr<nsIDOMLocation> location;
        if (NS_FAILED(GetDOMLocation(getter_AddRefs(location))) || !location)
            return E_UNEXPECTED;
        nsAutoString value(bstr);
        return NS_SUCCEEDED(location->Assign(value)) ? S_OK : E_FAIL;
    }

Here is the call graph for this function:

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_hash ( BSTR *  p) [inline, virtual, inherited]

Definition at line 142 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_host ( BSTR *  p) [inline, virtual, inherited]

Definition at line 92 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_hostname ( BSTR *  p) [inline, virtual, inherited]

Definition at line 102 of file IHTMLLocationImpl.h.

    {
        IHTMLLOCATION_GET_IMPL(Hostname);
    }
virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_href ( BSTR *  p) [inline, virtual, inherited]

Definition at line 72 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_pathname ( BSTR *  p) [inline, virtual, inherited]

Definition at line 122 of file IHTMLLocationImpl.h.

    {
        IHTMLLOCATION_GET_IMPL(Pathname);
    }
virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_port ( BSTR *  p) [inline, virtual, inherited]

Definition at line 112 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_protocol ( BSTR *  p) [inline, virtual, inherited]

Definition at line 82 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::get_search ( BSTR *  p) [inline, virtual, inherited]

Definition at line 132 of file IHTMLLocationImpl.h.

Here is the call graph for this function:

virtual nsresult IELocation::GetDOMLocation ( nsIDOMLocation **  aLocation) [inline, virtual]

Implements IHTMLLocationImpl< IELocation >.

Definition at line 187 of file XPCDocument.cpp.

    {
        *aLocation = mDOMLocation;
        NS_IF_ADDREF(*aLocation);
        return NS_OK;
    }

Definition at line 162 of file XPCDocument.cpp.

    {
        NS_PRECONDITION(pData != nsnull, "null ptr");

        mData = pData;

        // Get the DOM window
        nsCOMPtr<nsIDOMWindow> domWindow;
        NPN_GetValue(mData->pPluginInstance, NPNVDOMWindow, 
                     NS_STATIC_CAST(nsIDOMWindow **, getter_AddRefs(domWindow)));
        if (!domWindow)
        {
            return E_FAIL;
        }
        nsCOMPtr<nsIDOMWindowInternal> windowInternal = do_QueryInterface(domWindow);
        if (windowInternal)
        {
            windowInternal->GetLocation(getter_AddRefs(mDOMLocation));
        }
        if (!mDOMLocation)
            return E_FAIL;

        return S_OK;
    }

Here is the call graph for this function:

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_hash ( BSTR  v) [inline, virtual, inherited]

Definition at line 137 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_host ( BSTR  v) [inline, virtual, inherited]

Definition at line 87 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_hostname ( BSTR  v) [inline, virtual, inherited]

Definition at line 97 of file IHTMLLocationImpl.h.

    {
        IHTMLLOCATION_PUT_IMPL(Hostname);
    }
virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_href ( BSTR  v) [inline, virtual, inherited]

Definition at line 67 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_pathname ( BSTR  v) [inline, virtual, inherited]

Definition at line 117 of file IHTMLLocationImpl.h.

    {
        IHTMLLOCATION_PUT_IMPL(Pathname);
    }
virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_port ( BSTR  v) [inline, virtual, inherited]

Definition at line 107 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_protocol ( BSTR  v) [inline, virtual, inherited]

Definition at line 77 of file IHTMLLocationImpl.h.

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::put_search ( BSTR  v) [inline, virtual, inherited]

Definition at line 127 of file IHTMLLocationImpl.h.

Here is the call graph for this function:

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::reload ( VARIANT_BOOL  flag) [inline, virtual, inherited]

Definition at line 147 of file IHTMLLocationImpl.h.

    {
        nsCOMPtr<nsIDOMLocation> location;
        if (NS_FAILED(GetDOMLocation(getter_AddRefs(location))) || !location)
            return E_UNEXPECTED;
        return NS_SUCCEEDED(location->Reload(flag)) ? S_OK : E_FAIL;
    }

Here is the call graph for this function:

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::replace ( BSTR  bstr) [inline, virtual, inherited]

Definition at line 155 of file IHTMLLocationImpl.h.

    {
        nsCOMPtr<nsIDOMLocation> location;
        if (NS_FAILED(GetDOMLocation(getter_AddRefs(location))) || !location)
            return E_UNEXPECTED;
        nsAutoString value(bstr);
        return NS_SUCCEEDED(location->Replace(value)) ? S_OK : E_FAIL;
    }

Here is the call graph for this function:

virtual HRESULT STDMETHODCALLTYPE IHTMLLocationImpl< IELocation >::toString ( BSTR *  string) [inline, virtual, inherited]

Definition at line 173 of file IHTMLLocationImpl.h.

    {
        if (!string) return E_INVALIDARG;
        nsCOMPtr<nsIDOMLocation> location;
        if (NS_FAILED(GetDOMLocation(getter_AddRefs(location))) || !location)
            return E_UNEXPECTED;
        nsAutoString value;
        NS_ENSURE_SUCCESS(location->ToString(value), E_UNEXPECTED);
        *string = ::SysAllocString(value.get());
        return (*string) ? S_OK : E_OUTOFMEMORY;
    }

Here is the call graph for this function:


Member Data Documentation

Definition at line 155 of file XPCDocument.cpp.

Definition at line 156 of file XPCDocument.cpp.


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