Commit Graph

515 Commits

Author SHA1 Message Date
cls%seawood.org
6554bc353e Build jscpucfg using HOST_CC for cross-compiler builds. If cross-compiling, it needs the changes from the autoconf'd nspr tree to support using a different mdcpucfg.h
git-svn-id: svn://10.0.0.236/trunk@45662 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 05:27:14 +00:00
jband%netscape.com
e29d470c76 fix for bug 13001 - gotta let DefaultValue do its thing
git-svn-id: svn://10.0.0.236/trunk@45658 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 05:07:36 +00:00
jband%netscape.com
a9429a6afc Added Components.returnCode so that JS components can control the nsresult that xpconnect will return on their behalf without having to throw the number. Also better mapping of this code to Components.lastResult so that JS components calling JS components will work right with no special treatment
git-svn-id: svn://10.0.0.236/trunk@45588 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:19:42 +00:00
jband%netscape.com
66e11737f3 fix for bug 12954 - was failing to set rval on DeleteProperty call
git-svn-id: svn://10.0.0.236/trunk@45585 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:16:09 +00:00
jband%netscape.com
b03fe5e27c priming the JSContext stack in the test program
git-svn-id: svn://10.0.0.236/trunk@45583 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:11:54 +00:00
jband%netscape.com
e9381b0045 modernizing the undefined test in println
git-svn-id: svn://10.0.0.236/trunk@45582 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:11:16 +00:00
jband%netscape.com
e857a12919 removing unused var
git-svn-id: svn://10.0.0.236/trunk@45581 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:08:53 +00:00
briano%netscape.com
fc4ee09d97 Cleaned it up and eliminated the pointless #!gmake.
git-svn-id: svn://10.0.0.236/trunk@45578 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-02 00:06:06 +00:00
fur%netscape.com
2f98c8b1f3 Added capability to pass JS arrays as arguments to Java methods.
git-svn-id: svn://10.0.0.236/trunk@45473 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-01 14:37:21 +00:00
jband%netscape.com
ead0864f3d removing commented out code
git-svn-id: svn://10.0.0.236/trunk@45464 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-01 09:37:20 +00:00
mcafee%netscape.com
ab84959fd4 Fixing comment warning on Linux.
git-svn-id: svn://10.0.0.236/trunk@45461 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-01 08:12:24 +00:00
cyeh%netscape.com
c6342ee432 Remove IGNORE_MANIFEST=1. It doesn't do anything and it confuses people.
git-svn-id: svn://10.0.0.236/trunk@45379 18797224-902f-48f8-a5cc-f745e15eee43
1999-09-01 00:54:34 +00:00
rogerl%netscape.com
fc3ce85298 Fixed bug : 8672, using prototype from closure instead of function
Fixed memory leak- object acquired by 'in' operator was not being released.


git-svn-id: svn://10.0.0.236/trunk@45204 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-30 22:17:55 +00:00
rogerl%netscape.com
8b4e51dfee Changed handling of undefined limit and negative limit values to
String.split()


git-svn-id: svn://10.0.0.236/trunk@45175 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-30 22:05:56 +00:00
rogerl%netscape.com
1943b41acc Added new error messages for ecma_2 compliant regular expression handling.
git-svn-id: svn://10.0.0.236/trunk@45174 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-30 22:04:07 +00:00
fur%netscape.com
d42d901505 Eliminate obsolete error message
git-svn-id: svn://10.0.0.236/trunk@45063 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-29 16:55:02 +00:00
fur%netscape.com
6be8ddc8da Propagating fixes from SpiderMonkey140_BRANCH
git-svn-id: svn://10.0.0.236/trunk@45062 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-29 16:54:24 +00:00
jband%netscape.com
92f19008fa fix for bug 12466 - heuristic check for existence of 'message' and 'code' properties was broken. Added missing XPC_MSG_DEF
git-svn-id: svn://10.0.0.236/trunk@44579 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-26 00:04:14 +00:00
ramiro%netscape.com
cb934ee5cc Cleanup linking of libimg.
git-svn-id: svn://10.0.0.236/trunk@44493 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 13:37:11 +00:00
jband%netscape.com
f5d694013f - Added Support for 'foo instanceof Components.interaces.nsIFoo'.
- Added support for reflecting interface constants as Components.interfaces.nsIFoo.* (this may change).
- Only interfaces marked 'scriptable' are visible in the Components.interfaces array.
- Getting rid of some of the template style syntax.
- Added GetWStringCopied and GetWStringShared for lame tests of speed in wstring copies.
- Cleaned up more Unix warnings.


git-svn-id: svn://10.0.0.236/trunk@44460 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 06:01:42 +00:00
brendan%mozilla.org
d87f3f7b04 Massive spankage to capitalize C++ method and attribute name bindings, per
Architecture Item 6.3 (news://news.mozilla.org/37BA89CF.3823D6F9%40meer.net).


git-svn-id: svn://10.0.0.236/trunk@44456 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-25 05:26:25 +00:00
jband%netscape.com
ab520c184c Switched to newer style NS_IMPL_* macros. Fixed some warnings.
git-svn-id: svn://10.0.0.236/trunk@44127 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-23 08:01:33 +00:00
jband%netscape.com
d8db397370 changed a comment
git-svn-id: svn://10.0.0.236/trunk@44126 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-23 07:58:19 +00:00
jband%netscape.com
d38b37eed5 changed all those pesky instances of 'NULL' to 'nsnull'
git-svn-id: svn://10.0.0.236/trunk@44124 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-23 07:16:50 +00:00
jband%netscape.com
b854f5b075 - Move reflected result codes into Components.results - populated dynamically.
- Throw nsIXPCException objects rather than strings into JS.
- Better and more information in exceptions - including names of result codes and call stack.
- Added nsIJSErrorReport as attachment to exceptions for JS errors.
- Exceptions thrown in JS now get properly translated into result codes.
- Exceptions thrown JS->native->JS get propagated.
- Added per thread nsIXPConnect::[G,S]etPendingException.
- Added XPCConvert::JSValToXPCException - still needs better handling JS exception objects.
- Added XPCConvert::JSErrorToXPCException.
- No longer eat JS errrors in wrapped JS code called from native code.
- Declare xpconnect result codes in nsIXPConnect.h.
- Changed format of xpc.msg to give error names and descriptions.
- Fixed extraneous semicolons on XPC_IMPLEMENT_* macro usage.
- Using NS_IMPL_ISUPPORTS2 for nsIXPCScriptable declarations.
- Improve refcounting in xpccomponents.
- Turned some common code into macros.
- Converting some interfaces to use mccabe's NS_IMPL_* macros.
- Cleanup lots of trailing whitespace.
- Fixed idl comments.


git-svn-id: svn://10.0.0.236/trunk@44098 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-22 23:56:42 +00:00
ramiro%netscape.com
1784612f6b cleanup linking of libmozreg.
git-svn-id: svn://10.0.0.236/trunk@44002 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-21 15:41:53 +00:00
mccabe%netscape.com
91543218bc First cut at removing manual declaration of interface methods in implementation classes and replacing with xpidl-generated NS_DECL_NSIFOO macro.
Hopefully this'll help turn the copy-n-paste tide towards using this macro.


git-svn-id: svn://10.0.0.236/trunk@43988 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-21 08:54:47 +00:00
briano%netscape.com
f31270b20a General cleanup.
git-svn-id: svn://10.0.0.236/trunk@43967 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-21 03:06:46 +00:00
jband%netscape.com
2a25b65fb4 Rework nsIDs are reflected into JS. Expose HasInstance to nsIXPCScriptable. Initial work on making structured exceptions for JS. Switch nsIXPCScriptable implementations to use multiple inheritence rather that returning separate objects - stop breaking some xpcom rules. Fix NS_IMPL_QUERY_INTERFACE_SCRIPTABLE. Get rid of caching of nsIAllocator service. Add system to conditionally auto update the ThreadJSContextStack as we get called from JS. Expose Components.Exception and Components.ID ctors to JS. Convert more NULLs to nsnulls. Trim and or fix broken nsID tests.
git-svn-id: svn://10.0.0.236/trunk@43886 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-20 23:11:30 +00:00
brade%netscape.com
0c14bf5c0c remove mac compiler warnings
git-svn-id: svn://10.0.0.236/trunk@43816 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-20 13:30:39 +00:00
cls%seawood.org
c40becaa41 Removed all references to obsolete OBJDIR variable.
Removed various sections of config.mk & rules.mk that were only used by OBJDIR or by a non-autoconf build.


git-svn-id: svn://10.0.0.236/trunk@43791 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-20 06:52:59 +00:00
mgleeson1%netscape.com
8b5046b266 #
# The contents of this file are subject to the Netscape Public License
# Version 1.0 (the "NPL"); you may not use this file except in
# compliance with the NPL.  You may obtain a copy of the NPL at
# http://www.mozilla.org/NPL/
#
# Software distributed under the NPL is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
# for the specific language governing rights and limitations under the
# NPL.
#
# The Initial Developer of this code under the NPL is Netscape
# Communications Corporation.  Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation.  All Rights
# Reserved.
#

DEPTH		= ../../../..
topsrcdir	= @top_srcdir@
srcdir		= @srcdir@
VPATH		= @srcdir@

include $(DEPTH)/config/autoconf.mk

LIBRARY_NAME	= xpconnect
MODULE		= xpconnect

CPPSRCS		= \
		nsXPConnect.cpp \
		xpcarbitrary.cpp \
		xpccomponents.cpp \
		xpccontext.cpp \
		xpcconvert.cpp \
		xpcjsid.cpp \
		xpclog.cpp \
		xpcmaps.cpp \
		xpcmodule.cpp \
		xpcstack.cpp \
		xpcthreadcontext.cpp \
		xpcthrower.cpp \
		xpcwrappedjs.cpp \
		xpcwrappedjsclass.cpp \
		xpcwrappednative.cpp \
		xpcwrappednativeclass.cpp \
		xpcwrappednativejsops.cpp \
		$(NULL)

include $(topsrcdir)/config/config.mk

# XXX hackage!
# only copy the .so to components dir on platforms where xptcall is supported

# Unixish x86
ifneq (,$(filter SunOS Linux FreeBSD NetBSD BSD_OS,$(OS_ARCH)))
ifeq (86,$(findstring 86,$(OS_TEST)))
IS_COMPONENT	= 1
endif
endif

# Neutrino Cross-Compiled for x86
ifneq (,$(filter NTO,$(OS_TARGET)))
ifeq (86,$(findstring 86,$(OS_TEST)))
IS_COMPONENT	= 1
endif
endif

# Solaris/sparc
ifeq ($(OS_ARCH),SunOS)
ifneq (86,$(findstring 86,$(OS_TEST)))
IS_COMPONENT	= 1
endif
endif

# Linux/sparc
ifeq ($(OS_ARCH),Linux)
ifeq ($(OS_TEST),sparc)
IS_COMPONENT    = 1
endif
endif

# NetBSD/m68k
ifeq ($(OS_ARCH),NetBSD)
ifneq (,$(filter amiga atari hp300 mac68k mvme68k next68k sun3 sun3x x68k,$(OS_TEST)))
IS_COMPONENT	= 1
endif
endif

# BeOS/Intel
ifeq ($(OS_ARCH),BeOS)
ifeq ($(OS_TEST),BePC)
IS_COMPONENT	= 1
endif
endif

# HPUX
ifeq ($(OS_ARCH),HP-UX)
ifneq ($(CC),gcc)
IS_COMPONENT	= 1
endif
endif

# AIX
ifeq ($(OS_ARCH),AIX)
IS_COMPONENT	= 1
endif

# IRIX
ifeq ($(OS_ARCH),IRIX)
ifneq ($(basename $(OS_RELEASE)),5)
IS_COMPONENT	= 1
endif
endif

# OpenVMS (Alpha only at this point)
ifeq ($(OS_ARCH),OpenVMS)
ifeq ($(CPU_ARCH),Alpha)
IS_COMPONENT	= 1
endif
endif

# Linux or NetBSD ARM
ifneq (,$(filter Linux NetBSD,$(OS_ARCH)))
ifeq (arm,$(findstring arm,$(OS_TEST)))
IS_COMPONENT	= 1
endif
ifeq (sa110,$(findstring sa110,$(OS_TEST)))
IS_COMPONENT	= 1
endif
endif

include $(topsrcdir)/config/rules.mk

# this is automatically discovered under BeOS
ifneq ($(OS_ARCH),BeOS)
LIBS		+= \
		-lmozjs \
		-lxpcom \
		-lmozreg \
		$(NSPR_LIBS) \
		$(NULL)
endif

DEFINES		+= -DJSFILE -DJS_THREADSAFE


git-svn-id: svn://10.0.0.236/trunk@43693 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 21:30:47 +00:00
jband%netscape.com
a14de7a2e8 Fixing xptinfo bug with getting information about the type of an interface pointer parameter of a method when the method is inherited from another interface in another typelib file. The api needs to also pass along the method index in order to convey enough information to always give the right answer. Got that? :) Fixing users of this modified api also.
git-svn-id: svn://10.0.0.236/trunk@43580 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 10:12:30 +00:00
tbogard%aol.net
0e15bab13a XPCOM Cleanup: Fixed error checking on AggregatedQueryInterface agruments.
git-svn-id: svn://10.0.0.236/trunk@43557 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 05:48:10 +00:00
tbogard%aol.net
a74ab35457 XPCOM Cleanup: Fixed Aggregation macros in nsAgg.h to do aggregation correctly. Fixed usages and implementation of aggregation using these macros through out the tree.
git-svn-id: svn://10.0.0.236/trunk@43556 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-19 05:36:30 +00:00
mccabe%netscape.com
1999447bdb Changes to the xpidl compiler -
Error if an interface is declared [scriptable], but contains methods that can't be scripted because they refer to native-declared types, unless the method is declared [noscript].

This change is intended to make it easier to determine when an interface is not scriptable, and to make it easier to see what changes need to be made to make it scriptable.

As many of the .idl files in the tree defined [scriptable] interfaces that contained non-scriptable methods, I've sprinkled [noscript] throughout.  As the interfaces weren't scriptable anyway, this shouldn't change their visibility to javascript.


git-svn-id: svn://10.0.0.236/trunk@42960 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-10 12:18:01 +00:00
jband%netscape.com
ff333a38ba updating tests
git-svn-id: svn://10.0.0.236/trunk@42939 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-10 06:12:06 +00:00
toshok%hungry.com
ac965d16c1 we need keyCompare functions to these hashtables.
git-svn-id: svn://10.0.0.236/trunk@42932 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-10 05:25:14 +00:00
jband%netscape.com
5630b79f6c adding enumeration of CLSIDs and ProgIDs using code from Robert Ginda <rginda@ix.netcom.com>
git-svn-id: svn://10.0.0.236/trunk@42738 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-09 05:02:25 +00:00
brendan%mozilla.org
7c7947dd9f - Tighten up code in gc_root_marker that now allows for roots to contain jsvals
(tagged machine words, some of which when untagged are 8-byte-aligned GC heap
  pointers).
- Fix bad effects of rogue global-replace of JS_FREE by free.


git-svn-id: svn://10.0.0.236/trunk@42693 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-08 02:32:00 +00:00
jband%netscape.com
1e3a93ad77 add JS based test for nsISupportsPrimitives. Run using 'xpcshell xpctest_primitive.js'
git-svn-id: svn://10.0.0.236/trunk@42434 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-06 09:43:45 +00:00
rogerl%netscape.com
90cd3cd063 Added Linux/sparc component
git-svn-id: svn://10.0.0.236/trunk@42197 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-04 20:46:58 +00:00
jband%netscape.com
11316e2c3b adding modifications to support enumeration of interfaces from Robert Ginda <rginda@ix.netcom.com>. Also extending nsIXPCScriptable to support a set of flags - the only one implemented now allows for indicating that the objects static properties shouyld not be enumerated
git-svn-id: svn://10.0.0.236/trunk@42118 18797224-902f-48f8-a5cc-f745e15eee43
1999-08-04 06:22:27 +00:00
jband%netscape.com
626574bd3c fix for bug 10998 pointed out by rginda@ix.netcom.com. This was really just a refcounting bug
git-svn-id: svn://10.0.0.236/trunk@41728 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-31 18:53:40 +00:00
briano%netscape.com
40fcdcda46 OpenVMS-specific addition to force a POSIX build of jscpucfg.
git-svn-id: svn://10.0.0.236/trunk@41652 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-31 00:38:25 +00:00
jband%netscape.com
b9048d178d 1) fix the xpconnect factories to not use static objects.
2) add a test that acts as a sample for doing oberloaded methods on xpconnect wraped natives.
3) add a NOT_IMPLEMENTED method to wrapped native for getting the prototype JS object.
4) Set the global object of the JSContext as the wrapped native JSObject's parent when creating this JSObject. This makes JS code compiled against the wrapper actuall work!
5) fix the refcounting on factories in the tests/components module


git-svn-id: svn://10.0.0.236/trunk@41648 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-31 00:26:35 +00:00
jband%netscape.com
3d2fbbfb1c copy in most of the better error reporter from js.c
git-svn-id: svn://10.0.0.236/trunk@41646 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-31 00:19:50 +00:00
briano%netscape.com
2087356d68 Trivial elimination of some pointless macros as discussed in bug 8568. Approved by leaf@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@41509 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-29 01:18:12 +00:00
brendan%mozilla.org
e0f64c2c6e Fix warnings reported at http://tinderbox.mozilla.org/SeaMonkey/warnings.html, mostly unsigned/signed bothers.
git-svn-id: svn://10.0.0.236/trunk@41445 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-28 06:48:44 +00:00
briano%netscape.com
684f6b2907 Cleaned it up and changed the name of libreg.{a,so} to libmozreg.{a,so} to fix the conflict reported in bug 8568.
git-svn-id: svn://10.0.0.236/trunk@41354 18797224-902f-48f8-a5cc-f745e15eee43
1999-07-27 23:27:44 +00:00