Commit Graph

149341 Commits

Author SHA1 Message Date
mhammond%skippinet.com.au
e14bdef514 Add comments, remove prints, change repr(), and support event functions
not declaring some/all params.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181898 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-10 10:02:05 +00:00
cltbld
a9ac9ae0ee Automated update from host egg
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181891 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-10 04:02:11 +00:00
mhammond%skippinet.com.au
8acd27b54c Fold in patch to bug 129216 - Darwin build changes and *nix checks for
dynamic Python builds.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181890 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-10 03:57:25 +00:00
mhammond%skippinet.com.au
b032d89c5f Make things much prettier and add some automated tests.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181848 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 10:43:30 +00:00
mhammond%skippinet.com.au
97230e2a43 Change wrapping process.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181847 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 10:39:27 +00:00
mhammond%skippinet.com.au
7c58f19535 New functions in _nsdom and changes to wrapping process.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181846 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 10:33:13 +00:00
mhammond%skippinet.com.au
20205c380d Allow PYXPCOM_LOG_LEVEL and PYXPCOM_LOG_FILE from the environment to change
the logfile behaviour.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181844 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 09:18:26 +00:00
mhammond%skippinet.com.au
3b4e6118e8 Add PyObject_FromNSInterface as a public function.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181843 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:55:22 +00:00
mhammond%skippinet.com.au
311e841004 NS_CreateJSArgv takes a JSContext
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181842 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:50:19 +00:00
mhammond%skippinet.com.au
af254a2ae9 Keep the window argument around so they can be passed to any new language
contexts created when loading scripts.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181841 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:49:18 +00:00
mhammond%skippinet.com.au
36b9c72a2e EnsureScriptEnvironment forwards to outer and reindented. Remove code I
added that is no longer necessary.  Change a few assertions.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181840 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:48:17 +00:00
mhammond%skippinet.com.au
82877fabea Add a comment.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181839 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:42:20 +00:00
mhammond%skippinet.com.au
e8de1e2a13 NS_CreateJSArgv takes the jscontext as a param.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181838 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:41:38 +00:00
mhammond%skippinet.com.au
32a4ac7550 nsJSArgArray does string conversion.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181837 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-09 08:39:25 +00:00
mhammond%skippinet.com.au
c73211d45d Finish rename of logger to 'xpcom'
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181710 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-06 09:48:34 +00:00
mhammond%skippinet.com.au
cca222aacd Normalize the exception before printing it.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181705 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-06 07:29:54 +00:00
mhammond%skippinet.com.au
1742d0ad46 Only the caller of PrErr_Fetch can call PyErr_NormalizeException - it may
change the pointers!


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181704 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-06 07:29:20 +00:00
mhammond%skippinet.com.au
cd03200213 Go further in the concept of a "wrapped native". DOM objects get their
own nsISupports wrapper, which has support in context.py for expandos,
and all object returned by these objects are also this custom object.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181687 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-05 22:21:35 +00:00
mhammond%skippinet.com.au
e459c4c4f1 Avoid looking for _eq_ and _neq_ attributes, and always pass the raw
object to XPTC_InvokeByIndex.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181686 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-05 22:14:51 +00:00
mhammond%skippinet.com.au
00644c99bf Chage log name to simply 'xpcom' to match the package name.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181685 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-05 22:13:53 +00:00
mhammond%skippinet.com.au
22d53280da Few more nsVariant tests
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181684 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-05 22:13:06 +00:00
mhammond%skippinet.com.au
fc11431a03 Allow a Py_nsISupports object to control how interface objects obtained
from its methods or attributes are created.  Various nsVariant fixes


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181683 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-05 22:12:21 +00:00
mhammond%skippinet.com.au
ea52fe66cc Compiler package is different in Python 2.4.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181555 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 04:18:35 +00:00
mhammond%skippinet.com.au
3be7681577 s/min/?:/ to prevent yet another header on linux
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181545 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 03:21:10 +00:00
mhammond%skippinet.com.au
abf7b92d6e CompileEventHandler new args, and delegate most stuff to Python.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181534 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 02:10:34 +00:00
mhammond%skippinet.com.au
ee774d5992 Add nsdom package
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181533 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 02:07:27 +00:00
mhammond%skippinet.com.au
b88a09274a * nsContentUtils::GetEventArgName -> GetEventArgNames, so onerror event
is compiled with correct names
* nsIScriptContext->CompileEventHandler takes an array of names rather
  than 1.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181532 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 02:05:45 +00:00
mhammond%skippinet.com.au
3b02d87e23 Correct and new python related makefiles
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181531 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 01:58:07 +00:00
mhammond%skippinet.com.au
0bc2eb5a5f Oops - checked in Makefile instead of Makefile.in
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181530 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 01:35:41 +00:00
mhammond%skippinet.com.au
679e0eb9ca nsdom package, which does most of the grunt work.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181529 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 01:34:21 +00:00
mhammond%skippinet.com.au
8ec88ff7b4 Add error event tests
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181528 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 01:32:10 +00:00
mhammond%skippinet.com.au
16deaf6871 Delete stale module.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181519 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 00:39:08 +00:00
mhammond%skippinet.com.au
6f223094ae new xpcom.primitives module for nsISupportsPrimitive interface helpers
and tests.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181517 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 00:36:36 +00:00
mhammond%skippinet.com.au
d6a450b609 2nd param to Component() is optional, and correct typo in docstring.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181515 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 00:35:06 +00:00
mhammond%skippinet.com.au
a077cf0cc8 Add public PyObject_AsNSString, and refactor VariantUtils to use it when
appropriate.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181514 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-04 00:33:58 +00:00
mhammond%skippinet.com.au
8e66ae6d1a scripttype->script-type
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181461 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-03 09:51:50 +00:00
mhammond%skippinet.com.au
de95cd0001 shaver insists the attribute be "script-type" (and offered to argue with
Brendan about it :)


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181454 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 23:16:35 +00:00
mhammond%skippinet.com.au
a2758ff8ca Correct error handling binding to an event handler, and fix new
nsJSArgArray.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181453 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 23:14:57 +00:00
mhammond%skippinet.com.au
3d082bdfe0 Brings things up to date with the rest of the world.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181434 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 13:29:11 +00:00
mhammond%skippinet.com.au
c27dc527ee * Introduce nsIJSArgArray interface, to allow a native JS argv pointer to
be passed.  Matching component that supports the new interface and
  nsIArray.  Thus js->js calls can avoid any nsISupports conversion
  overhead.  Every JS specific event firer uses this.

* New NS_SL_* macros to make it easy for objects that use an array
  of nsIScriptContext objects.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181433 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 13:24:41 +00:00
mhammond%skippinet.com.au
4686cd2578 * Bring nsISupportsPrimitives support into the unicode world.
* test_isupports_primitives moves to unittest and tests unicode.
* More overloads for PyObject_FromNSString, dropping PyUnicode_FromPRUnichar.
* PyExc_MemoryError translated to NS_ERROR_OUT_OF_MEMORY
* PyXPCOM_FormatCurrentException becomes public.
* Add more type slots, even though we don't use them yet.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181432 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 13:00:15 +00:00
mhammond%skippinet.com.au
1b5cd0ea52 Give JS the name 'application/javascript' when used in explicit
'script-type' attributes or any other context other than the existing
hard-coded content-sink implementations.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181429 18797224-902f-48f8-a5cc-f745e15eee43
2005-10-02 11:37:09 +00:00
mhammond%skippinet.com.au
4f85bbbde6 Merge patch from https://bugzilla.mozilla.org/show_bug.cgi?id=299205
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@181025 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-27 03:05:54 +00:00
mhammond%skippinet.com.au
d5b1eb8ffc * Have a bash at adding a "default script language" to nsIContent.
* When merging overlays, use the default script language specified
   in the overlay for attributes, and eagerly compile them if the language
   is not the nodes default.
* Remove mLangID from nsIXULPrototypeAttribute.
* nsIScriptGlobalObject::EnsureScriptEnvironment(PRUint32 aLangID) to
   allow a global to set itself up for a new language.


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180644 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-20 12:40:41 +00:00
mhammond%skippinet.com.au
a16fa16c39 Fix type in comments.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180643 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-20 12:37:59 +00:00
mhammond%skippinet.com.au
8327630cde Add a test of different attributes with different default languages.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180641 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-20 12:00:07 +00:00
mhammond%skippinet.com.au
329bdfca9f Get things working with the new event regime.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180486 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-18 09:00:40 +00:00
mhammond%skippinet.com.au
e7f5eb6c2c Revert some of the "script binding" work I did into a model closer to the
existing one


git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180485 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-18 08:59:31 +00:00
mhammond%skippinet.com.au
24fcf91e8b Update comments.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180013 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-12 08:49:36 +00:00
mhammond%skippinet.com.au
b337a33a36 Plug a leak of an nsIScriptContext I introduced.
git-svn-id: svn://10.0.0.236/branches/DOM_AGNOSTIC_BRANCH@180012 18797224-902f-48f8-a5cc-f745e15eee43
2005-09-12 08:47:49 +00:00