internal static GeckoNode Create(nsIDOMNode domObject) { if (domObject == null) { return(null); } nsIDOMHTMLElement element = Xpcom.QueryInterface <nsIDOMHTMLElement>(domObject); if (element != null) { return(GeckoElement.Create(element)); } nsIDOMAttr attr = Xpcom.QueryInterface <nsIDOMAttr>(domObject); if (attr != null) { return(GeckoAttribute.Create(attr)); } return(new GeckoNode(domObject)); }
public CookieManager() { var manager = Xpcom.GetService <nsICookieManager2>("@mozilla.org/cookiemanager;1"); _cookieManager = Xpcom.QueryInterface <nsICookieManager2>(manager); }
internal GeckoResponse(nsIRequest request) { Channel = Xpcom.QueryInterface <nsIChannel>(request); HttpChannel = Xpcom.QueryInterface <nsIHttpChannel>(request); }
public void Print() { nsIWebBrowserPrint print = Xpcom.QueryInterface <nsIWebBrowserPrint>(this.DomWindow); print.Print(null, null); }
public GeckoStyleSheetService() { StyleSheetService = Xpcom.GetService <nsIStyleSheetService>("@mozilla.org/content/style-sheet-service;1"); StyleSheetService = Xpcom.QueryInterface <nsIStyleSheetService>(StyleSheetService); }