queryinterface for nsIBaseWindow on nsIWebbrowser fails with firefox 19

RESOLVED INVALID

Status

()

RESOLVED INVALID
6 years ago
6 years ago

People

(Reporter: tmax_dev, Unassigned)

Tracking

19 Branch
x86_64
Windows 7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

6 years ago
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4

Steps to reproduce:

I just ran my old embedding code (like also mentioned here http://www-archive.mozilla.org/projects/embedding/PublicAPIs.html)

 // Create a nsWebBrowser instance...
 webBrowser = do_CreateInstance(NS_WEBBROWSER_CONTRACTID, &rv);
 if (NS_FAILED(rv)) return rv;

// Give the WebBrowser a pointer to the embedding component which
// implements the callback interfaces. Replace 'this' with
// an appropriate object...
rv = webBrowser->SetContainerWindow((nsIWebBrowserChrome*)this);
if (NS_FAILED(rv)) return rv;
baseWindow = do_QueryInterface(webBrowser);




Actual results:

baseWindow is null with firefox19/xulrunner19


Expected results:

baseWindow should contain a valid pointer to use in my following code.
(Reporter)

Comment 1

6 years ago
I'm now getting the same behavior when using Firefox 18 beta 2.

Any hints on that issue ?

Comment 2

6 years ago
You're compiling against source or a matching SDK? nsWebBrowser still implements nsIBaseWindow (http://mxr.mozilla.org/mozilla-central/source/embedding/browser/webBrowser/nsWebBrowser.cpp#137) so I suspect this is just a compilation problem with mismatched IIDs.

Comment 3

6 years ago
fyi the IID of nsIBaseWindow changed in http://hg.mozilla.org/mozilla-central/rev/5ec67c1dd2e1 which for FF19.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.