int IsNonBlocking (int /*long*/ _retval) { /* blocking */ XPCOM.memmove (_retval, new boolean[] {false}); return XPCOM.NS_OK; } }
int Available (long /*int*/ _retval) { int available = buffer == null ? 0 : buffer.length - index; XPCOM.memmove (_retval, new int[] {available}, 4); return XPCOM.NS_OK; }
int IsWindowModal (long /*int*/ retval) { boolean result = (chromeFlags & nsIWebBrowserChrome.CHROME_MODAL) != 0; XPCOM.memmove (retval, new boolean[] {result}); return XPCOM.NS_OK; }
int IsNonBlocking (long /*int*/ _retval) { /* blocking */ XPCOM.memmove (_retval, new boolean[] {false}); return XPCOM.NS_OK; } }
int IsWindowModal (int /*long*/ retval) { boolean result = (chromeFlags & nsIWebBrowserChrome.CHROME_MODAL) != 0; XPCOM.memmove (retval, new boolean[] {result}); return XPCOM.NS_OK; }
int GetChromeFlags (long /*int*/ aChromeFlags) { int[] ret = new int[1]; ret[0] = chromeFlags; XPCOM.memmove (aChromeFlags, ret, 4); /* PRUint32 */ return XPCOM.NS_OK; }
int IsWindowModal (long /*int*/ retval) { boolean result = (chromeFlags & nsIWebBrowserChrome.CHROME_MODAL) != 0; XPCOM.memmove (retval, new boolean[] {result}); return XPCOM.NS_OK; }
int GetSiteWindow (int /*long*/ aSiteWindow) { /* * This is expected to be an HWND on Windows, a GtkWidget* on GTK, and * a WindowPtr on OS X. This callback is invoked on Windows when the * print dialog is to be shown. If no handle is returned then no print * dialog is shown with XULRunner versions < 4. */ int /*long*/ siteWindow = delegate.getSiteWindow (); XPCOM.memmove (aSiteWindow, new int /*long*/[] {siteWindow}, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int GetWebBrowser (long /*int*/ aWebBrowser) { long /*int*/[] ret = new long /*int*/[1]; if (webBrowser != null) { webBrowser.AddRef (); ret[0] = webBrowser.getAddress (); } XPCOM.memmove (aWebBrowser, ret, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int GetNext (long /*int*/ _retval) { if (values == null || index == values.length) return XPCOM.NS_ERROR_UNEXPECTED; nsISupports value = values[index++]; value.AddRef (); XPCOM.memmove (_retval, new long /*int*/[] {value.getAddress ()}, C.PTR_SIZEOF); return XPCOM.NS_OK; } }
public void dispose() { // free the memory for this reference int /*long*/[] pVtable = new int /*long*/[1]; XPCOM.memmove (pVtable, ppVtable, C.PTR_SIZEOF); C.free (pVtable[0]); C.free (ppVtable); // remove this ppVtable from the list ObjectMap.remove (new LONG (ppVtable)); ppVtable = 0; }
public void dispose() { // free the memory for this reference int /*long*/[] pVtable = new int /*long*/[1]; XPCOM.memmove (pVtable, ppVtable, C.PTR_SIZEOF); C.free (pVtable[0]); C.free (ppVtable); // remove this ppVtable from the list ObjectMap.remove (new LONG (ppVtable)); ppVtable = 0; }
public boolean Equals(nsID other) { int /*long*/ ptr = XPCOM.nsID_new (); XPCOM.memmove (ptr, this, nsID.sizeof); int /*long*/ otherPtr = XPCOM.nsID_new (); XPCOM.memmove (otherPtr, other, nsID.sizeof); boolean result = XPCOM.nsID_Equals (ptr, otherPtr) != 0; XPCOM.nsID_delete (ptr); XPCOM.nsID_delete (otherPtr); return result; }
int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { Download_1_8 download = new Download_1_8 (); download.AddRef (); XPCOM.memmove (result, new int /*long*/[] {download.getAddress ()}, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int GetVisibility (long /*int*/ aVisibility) { boolean visible = browser.isVisible () && !browser.getShell ().getMinimized (); XPCOM.memmove (aVisibility, new boolean[] {visible}); return XPCOM.NS_OK; }
int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { Download_1_8 download = new Download_1_8 (); download.AddRef (); XPCOM.memmove (result, new int /*long*/[] {download.getAddress ()}, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int CreateInstance (long /*int*/ aOuter, long /*int*/ iid, long /*int*/ result) { External external = new External (); external.AddRef (); XPCOM.memmove (result, new long /*int*/[] {external.getAddress ()}, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int GetDisplayDirectory (long /*int*/ aDisplayDirectory) { String directoryName = directory != null ? directory : ""; //$NON-NLS-1$ nsEmbedString path = new nsEmbedString (directoryName); long /*int*/[] file = new long /*int*/[1]; int rc = XPCOM.NS_NewLocalFile (path.getAddress (), 1, file); path.dispose (); if (rc != XPCOM.NS_OK) Mozilla.error (rc); if (file[0] == 0) Mozilla.error (XPCOM.NS_ERROR_NULL_POINTER); XPCOM.memmove (aDisplayDirectory, file, C.PTR_SIZEOF); return XPCOM.NS_OK; }
int getScriptObject (int /*long*/ aContext, int /*long*/ aScriptObject) { byte[] jsLibPath = Mozilla.getJSLibPathBytes (); int /*long*/ nativeContext = XPCOM.nsIScriptContext_GetNativeContext (aContext); int /*long*/ globalJSObject = XPCOM.JS_GetGlobalObject (jsLibPath, nativeContext); int /*long*/ newObject = XPCOM.JS_NewObject (jsLibPath, nativeContext, 0, 0, globalJSObject); byte[] functionName = MozillaDelegate.wcsToMbcs (null, CALLJAVA, true); int flags = XPCOM.JSPROP_ENUMERATE | XPCOM.JSPROP_READONLY | XPCOM.JSPROP_PERMANENT; XPCOM.JS_DefineFunction (jsLibPath, nativeContext, newObject, functionName, XPCOM.CALLBACK_JSNative (CallJavaProc.getAddress ()), 3, flags); XPCOM.memmove (aScriptObject, new int /*long*/[] {newObject}, C.PTR_SIZEOF); return XPCOM.NS_OK; }