Граф коммитов

43243 Коммитов

Автор SHA1 Сообщение Дата
shawnp%earthling.net b8b7888624 Added constructor needed for integration with Xlib gfx toolkit. Reviewed by
ramiro@netscape.com.
1999-10-05 01:28:24 +00:00
shawnp%earthling.net a2846627fe Implemented stub SetCheckboxType() and GetCheckboxType() functions.
Reviewed by ramiro@netscape.com.
1999-10-05 01:27:44 +00:00
shawnp%earthling.net 6e54805ae8 Implemented stub GetEnabled() and IsHelpMenu() functions. Reviewed by
ramiro@netscape.com.
1999-10-05 01:26:39 +00:00
kipp%netscape.com 7b7c3b1eb6 Disabled leak cleanup until other reviews come in 1999-10-05 01:26:14 +00:00
dp%netscape.com 82c29aa82a Fixing build bustage. 1999-10-05 01:25:55 +00:00
shawnp%earthling.net f3229171a3 Updated to better match values used by the gtk widget toolkit (assuming
those are more correct values). Reviewed by ramiro@netscape.com.
1999-10-05 01:24:46 +00:00
shawnp%earthling.net 153c96aa91 Added a static function to determine at runtime what gfx toolkit is being
used. Reviewed by ramiro@netscape.com.
1999-10-05 01:23:47 +00:00
shawnp%earthling.net d8db4adee0 Now link in libxlibgrb.so when building libwidgetqt.so so that Qt can work
with the Xlib gfx toolkit. Reviewed by ramiro@netscape.com.
1999-10-05 01:22:48 +00:00
shawnp%earthling.net 017409f3ab Added missing entries to the menus. Added key accessors for menu items that
were missing them. Reviewed by ramiro@netscape.com.
1999-10-05 01:21:29 +00:00
jband%netscape.com a7173aa30d NOT PART OF BUILD updating status page 1999-10-05 00:53:26 +00:00
dmose%mozilla.org 9d7478e8be update license boilerplate to NPL dual w/GPL, r=norris@netscape,a=norris@netscape.com 1999-10-05 00:44:05 +00:00
kipp%netscape.com de644b01c4 Found another type of symbol that indicates the presence of a static ctor 1999-10-05 00:39:48 +00:00
troy%netscape.com 06c4d97c3b Removed unused data member 1999-10-05 00:32:07 +00:00
kipp%netscape.com be1c67e0e0 r=ramiro; fix uninitialized refcnt bug that triggers an assertion when you're lucky 1999-10-05 00:31:55 +00:00
briano%netscape.com e245370830 Automated update 1999-10-05 00:31:43 +00:00
alecf%netscape.com d2bf42255e add detection for broken mmap()/write() behavior
contributed by jim_nance@yahoo.com
r=alecf
1999-10-05 00:29:09 +00:00
rogerl%netscape.com 079188169c First cut at errors as exceptions - These changes should be benign since
the errors are being wrapped by runtime exceptions and still need to be
explicitly caught (this is happening in the interpreter, but not in
generated code).
1999-10-05 00:21:07 +00:00
waterson%netscape.com b9528fb7bc Bug 15460. Expose XML element creation via nsIXMLElementFactory interface. r=kipp. 1999-10-05 00:12:21 +00:00
kipp%netscape.com ce0e9a63f0 r=dp; more leak tracking hooks added 1999-10-05 00:08:41 +00:00
waterson%netscape.com 2efd076b82 Bug 15367. Dump 'class' instead of 'file/line' for NS_LOG_REFCNT. r=shaver,dp 1999-10-05 00:07:54 +00:00
kipp%netscape.com b18e3d2122 r=dp; cleanup xpcom library too during shutdown to reduce global leaks 1999-10-05 00:07:39 +00:00
kipp%netscape.com a3d7e7cf09 r=vidur; fixed a memory of a script content object 1999-10-05 00:05:38 +00:00
rhp%netscape.com b8a801fabd Fixes for bug #15363 and #14675 - reviewer bienvenu 1999-10-05 00:03:20 +00:00
kipp%netscape.com d47f06d32d r=troy; missed checkin from last weeks module carpool 1999-10-04 23:56:57 +00:00
alecf%netscape.com 1ecd2e3371 exorcism of net.h from IMAP
r=mscott
1999-10-04 23:53:56 +00:00
alecf%netscape.com 561a1fbd52 Combined checkin:
- convert Compose enums to IDL #13261
- exorcise net.h from compose and mime
r=ducarroz and rhp on both
1999-10-04 23:50:56 +00:00
nhotta%netscape.com db0e490c2c Bug fix 15017, reviewed by akkana. Override SetDocumentCharacterSet for HTMLEditor to update META charset tag if exists. 1999-10-04 23:50:27 +00:00
kipp%netscape.com b45407f465 r=ramiro; fixed memory leak of a font-metrics object; also added in ctor/dtor counting for leak debugging 1999-10-04 23:48:55 +00:00
troy%netscape.com d6fe7542eb Space optimization for nsTableFrame. r=karnaze@netscape.com
- changed mBorderEdges to be heap allocated (only needed for collapsing border model)
- made the 8 boolean data members into bitfields
- changed mColumnWidths to be as small as necessary instead of defaulting its size to 100 elements
1999-10-04 23:48:05 +00:00
troy%netscape.com 7fd0cda385 Made sure mOutsideEdge is initizlied 1999-10-04 23:44:44 +00:00
ducarroz%netscape.com 88a9f70faa Fix for bug 14561, Already checked in the M10 BRANCH. Error must have negative value. A=choffman, R=mscott 1999-10-04 23:43:57 +00:00
troy%netscape.com da1cf6530f Performance optimizations. r=kmcclusk@netscape.com
I made the commonly accessed stock objects global, and I optimized the
SetupSolidPen() code
1999-10-04 23:42:28 +00:00
kipp%netscape.com b8fa545444 r=dp; tidy up exit logic to release more global junk (space team work) 1999-10-04 23:41:53 +00:00
kipp%netscape.com 2d86782610 r=dp,vidur,beard; close up some memory leaks related to shutdown of the viewer 1999-10-04 23:41:25 +00:00
kipp%netscape.com 9b78e0fd9d r=dp; implement some macros to help track memory leaks 1999-10-04 23:36:18 +00:00
kipp%netscape.com a5969c2c3f r=brendan; applied changes recommended by brendan 1999-10-04 23:35:51 +00:00
peterl%netscape.com 69c028cae8 fixed leak of undisplayed content map nodes (which leak style contexts)
r=kipp
1999-10-04 23:33:23 +00:00
valeski%netscape.com 12bba9e092 NOT part of the build. 1999-10-04 23:13:11 +00:00
valeski%netscape.com 7ffe53f79f NOT part of the build. 1999-10-04 23:12:02 +00:00
norris%netscape.com 4c4cc4d82a Fix up makefiles; previous patch was mis-applied. 1999-10-04 21:31:21 +00:00
morse%netscape.com da525ed2ee oops -- I carelessly left out a carriage return in my last checkin 1999-10-04 21:07:01 +00:00
morse%netscape.com bca9fba5b6 fix profile-manager bustage in todays build, checked in by request of leaf 1999-10-04 20:59:16 +00:00
kipp%netscape.com da92fd1a0c Fixed uninitialized members in the TreeNode struct 1999-10-04 20:25:53 +00:00
norris%netscape.com b1ecbb62ba Fix bug found by Andrew Wason (see below).
Problem was that one transformation of a node to GETVAR wasn't protected by a check of inWithStatement().

======================================
Subject:
        multiple scopes
   Date:
        Fri, 01 Oct 1999 12:39:14 -0400
   From:
        Andrew Wason <aw@softcom.com>
     To:
        norris@netscape.com
    CC:
        Howard Lin <howard@softcom.com>




When I create two scopes, and one scope evaulates a string in the other
scope, it works.  However, if I do this while handling an exception thrown
within a JavaAdapter method, it fails with an exception.

Run the attached Java program with the two script files.  scope1.js
evaluates a string "printMessage" in the scope of scope2.js.  This returns
a function object which is then invoked.  This works in 3 cases, but fails
in the 4th (in the catch in the JavaAdapter).  Even in the 4th case where
it fails, printing the function object looks normal.

Am I doing something wrong, or is there a bug here?

java CrossScope scope1.js scope2.js

Outside of JavaAdapter
works before exception
works after exception
Inside of JavaAdapter
works before exception
Caught exception
pma=
function printMessage(msg) {
     java.lang.System.out.println(msg);
}

Exception in thread "main" org.mozilla.javascript.JavaScriptException:
org.mozilla.javascript.EvaluatorException: The undefined value has no
properties.
         at
org.mozilla.javascript.JavaScriptException.wrapException(JavaScriptException
.java:61)
         at
org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java,
Compiled Code)
         at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1256)
         at org.mozilla.javascript.Interpreter.interpret(Interpreter.java,
Compiled Code)
         at
org.mozilla.javascript.InterpretedScript.call(InterpretedScript.java:49)
         at
org.mozilla.javascript.InterpretedScript.exec(InterpretedScript.java:37)
         at org.mozilla.javascript.Context.evaluateReader(Context.java:697)
         at CrossScope.<init>(CrossScope.java:30)
         at CrossScope.main(CrossScope.java:10)


Thanks,
Andrew

import java.io.*;
import org.mozilla.javascript.*;

public class CrossScope {
	private Context m_jsContext;
	private Scriptable m_scope1;
	private Scriptable m_scope2;

	public static void main(String args[]) throws Exception {
		new CrossScope(args[0], args[1]);
	}

	private CrossScope(String strFile1, String strFile2) throws Exception {
		// Associate Context with main thread
		m_jsContext = Context.enter();
                m_jsContext.setOptimizationLevel(-1);

		// Init scope1, expose Scope object
  		m_scope1 = m_jsContext.initStandardObjects(new ImporterTopLevel());
		m_scope1.put("Scope", m_scope1, this);

		// Init scope2
		m_scope2 = m_jsContext.initStandardObjects(new ImporterTopLevel());

		// Run script in scope2
		Reader r2 = new FileReader(strFile2);
		m_jsContext.evaluateReader(m_scope2, r2, strFile2, 1, null);

		// Eval input JS in scope1 - it can in turn eval JS over in scope2
		Reader r1 = new FileReader(strFile1);
		Object obj = m_jsContext.evaluateReader(m_scope1, r1, strFile1, 1, null);
		if (obj instanceof Throwable)
			((Throwable)obj).printStackTrace();

		m_jsContext.exit();
	}

	public Object scope1Eval(String str) throws JavaScriptException {
			Context cx = Context.enter(m_jsContext);
			Object objResult = cx.evaluateString(m_scope1, str, "scope1EvalString", 1, null);
			cx.exit();
			return objResult;
	}

	public Object scope2Eval(String str) throws JavaScriptException {
			Context cx = Context.enter(m_jsContext);
			Object objResult = cx.evaluateString(m_scope2, str, "scope2EvalString", 1, null);
			cx.exit();
			return objResult;
	}
}


// Scope1

importPackage(java.lang);

System.out.println("Outside of JavaAdapter");

try {
	var pm = Scope.scope2Eval("printMessage");
	pm("works before exception");
	System.arraycopy(null, 5, null, 5, 100);
} catch (e) {
	var pma = Scope.scope2Eval("printMessage");
	pma("works after exception");
}

var obj = new Runnable() {
	run: function() {
		System.out.println("Inside of JavaAdapter");
		try {
			var pm = Scope.scope2Eval("printMessage");
			pm("works before exception");
			System.arraycopy(null, 5, null, 5, 100);
		} catch (e) {
			System.out.println("Caught exception");
			var pma = Scope.scope2Eval("printMessage");
			System.out.println("pma=" + pma);
			pma("works after exception");
		}
	}
};

obj.run();



// Scope2

function printMessage(msg) {
	java.lang.System.out.println(msg);
}
1999-10-04 18:27:30 +00:00
endico%mozilla.org 14751442af make file searches case insentive 1999-10-04 18:11:27 +00:00
tao%netscape.com a1e78e2205 First checkin of da-DK files (from Henrik) into l10n/lang. 1999-10-04 18:01:19 +00:00
valeski%netscape.com 3c9e0c4585 adding keyword protocol handler to tree. this code is NOT in the build yet. 1999-10-04 16:34:45 +00:00
kipp%netscape.com 9a999cfdbe Added -R flag and logic for managing refcnt dumping better 1999-10-04 16:32:03 +00:00
neeti%netscape.com bbe0ad61fd cookie module conversion done 1999-10-04 14:34:54 +00:00
neeti%netscape.com a150a17c4e *** empty log message *** 1999-10-04 14:08:52 +00:00