You are currently viewing a snapshot of www.mozilla.org taken on April 21, 2008. Most of this content is highly out of date (some pages haven't been updated since the project began in 1998) and exists for historical purposes only. If there are any pages on this archive site that you think should be added back to www.mozilla.org, please file a bug.



Window binding/creation snippet [ << Previous | Contents | Next >> ]
This fragment binds your native window to the nsIWebBrowser's nsIBaseWindow, then instigates final window creation.
  // Initialize WebBrowser with native parent window
  rv = baseWindow->InitWindow(nativeWindow, null,
                              x, y, cx, cy);
  if (NS_FAILED(rv)) return rv;

  // Create the child window for the WebBrowser
  rv = baseWindow->Create();
  if (NS_FAILED(rv)) return rv;