Commit Graph

1399 Commits

Author SHA1 Message Date
Andrew McCreight
8f774dbad9 Bug 744103, part 2 - Change NoteScriptChild to NoteJSChild. r=smaug 2012-05-03 12:28:10 -07:00
Boris Zbarsky
2299a42041 Bug 742217. Reduce the use of nested namespaces in our binding code. r=peterv,bent
In the new setup, all per-interface DOM binding files are exported into
mozilla/dom.  General files not specific to an interface are also exported into
mozilla/dom.

In terms of namespaces, most things now live in mozilla::dom.  Each interface
Foo that has generated code has a mozilla::dom::FooBinding namespace for said
generated code (and possibly a mozilla::bindings::FooBinding_workers if there's
separate codegen for workers).

IDL enums are a bit weird: since the name of the enum and the names of its
entries all end up in the same namespace, we still generate a C++ namespace
with the name of the IDL enum type with "Values" appended to it, with a
::valuelist inside for the actual C++ enum.  We then typedef
EnumFooValues::valuelist to EnumFoo.  That makes it a bit more difficult to
refer to the values, but means that values from different enums don't collide
with each other.

The enums with the proto and constructor IDs in them now live under the
mozilla::dom::prototypes and mozilla::dom::constructors namespaces respectively.
Again, this lets us deal sanely with the whole "enum value names are flattened
into the namespace the enum is in" deal.

The main benefit of this setup (and the reason "Binding" got appended to the
per-interface namespaces) is that this way "using mozilla::dom" should Just
Work for consumers and still allow C++ code to sanely use the IDL interface
names for concrete classes, which is fairly desirable.

--HG--
rename : dom/bindings/Utils.cpp => dom/bindings/BindingUtils.cpp
rename : dom/bindings/Utils.h => dom/bindings/BindingUtils.h
2012-05-03 00:35:38 -04:00
Nicholas Nethercote
59ad4345e7 Bug 747803 - Remove NS_SIZE_IN_HEAP. r=bz. 2012-04-19 14:15:23 +10:00
Ehsan Akhgari
166aca09f9 Merge mozilla-central into mozilla-inbound 2012-04-24 21:29:44 -04:00
Nathan Froyd
dc2f118fd3 Bug 746285 - pack nsXBLBinding more carefully for 64-bit; r=bz 2012-04-17 15:23:11 -04:00
Jason Orendorff
674e87f181 Bug 738617 - Revert changeset 6d139ebc0f43 (bug 730139). Reserving let breaks some web sites. r=Waldo, a=mfinkle. 2012-04-18 15:07:11 -05:00
Mark Capella
260d060e01 Bug 744332 - Remove nsXULPrototypeScript::ScriptObjectHolder::mLangID. r=jst, f=Ms2ger 2012-04-24 18:31:28 -04:00
Jonathan Watt
bbd2635d4e Bug 745352 - Remove broken include paths from content Makefile.in files. r=dholbert. 2012-01-19 15:36:53 +00:00
Daniel Holbert
8525205768 Bug 369560 followup: Soften language in unusual-but-innocuous NS_WARNING for XBL docs with no root element. r=bz 2012-04-08 18:37:41 -07:00
Mark Capella
cd7e385481 Bug 741580 - Remove nsXULPrototype Element mScriptTypeID, r=ms2ger,jst 2012-04-05 12:20:44 -07:00
Igor Bukanov
2d04a4fe3d Bug 737365 - stop using the cx during finalization, part 1.
This part changes the signatures for various finalization API to take
not JSContext* but rather either JSFreeOp structure or its
library-private counterpart FreeOp. These structures wrap parameters
that are passed to the finalizers removing most of explicit dependencies
on JSContext in the finalization code.
2012-03-19 15:34:55 +01:00
Mark Capella
62db5d9389 Bug 738380 - Remove nsINode::{GetScriptTypeID, SetScriptTypeID}, nsIScriptContext::GetScriptTypeID, nsIScriptRuntime::GetScriptTypeID; r=jst 2012-04-01 14:47:48 +02:00
Ed Morley
18b9148c4f Merge last PGO-green changeset of mozilla-inbound to mozilla-central 2012-03-31 22:41:59 +01:00
Olli Pettay
c7a649ab35 Bug 641821, MutationObserver, r=sicking
--HG--
extra : rebase_source : a680c883b22976edf38eea23fb516215e081084f
2012-03-31 09:30:13 -07:00
Peter Van der Beken
ed510d3506 Fix for bug 740069 (Generate JS bindings in C++ with a python script for DOM objects on the main thread and in workers. Infrastructure and new bindings for XMLHttpRequest). Patch by bent/bz/bholley/jst/khuey/peterv, r=bent/bz/bholley/jlebar/khuey/peterv/sicking/smaug.
--HG--
rename : js/xpconnect/tests/mochitest/test_bug462428.html => dom/bindings/test/test_lookupGetter.html
2012-03-30 21:42:20 -07:00
Phil Ringnalda
16b8634b73 Back out b00bf7f3869c (bug 737976) for apparently causing mochitest-1 leaks on a CLOSED TREE 2012-03-28 22:43:09 -07:00
Kyle Huey
33073664dc Bug 737976: Remove nsINodeInfo. rs=bent 2012-03-28 19:07:37 -07:00
Nathan Froyd
8c5b9206cd Bug 739962 - fix -Wunused-but-set-variable warnings in content; r=bent 2012-03-28 09:14:33 -04:00
Matt Brubeck
626f101539 Merge mozilla-central and mozilla-inbound 2012-03-24 09:05:27 -07:00
Peter Van der Beken
cba2d2e2ac Bug 738593 - Rename IsProxy to IsDOMBinding; r=mrbkap 2012-03-16 16:44:09 +01:00
Andrew McCreight
80d210f308 Bug 732495 - clean up refcounting for nsXBLDocumentInfo creation to fix leak. r=smaug 2012-03-22 13:46:03 -07:00
Henri Sivonen
31192f4b01 Bug 737417 part 1 - Split charset source constants out of nsIParser.h. r=smaug. 2012-03-22 16:42:42 +02:00
Jim Mathies
71cea19097 Bug 737983 - win8 fixup for generic keyword collision, r=smaug. 2012-03-22 09:18:41 -05:00
Boris Zbarsky
291c1ee048 Bug 700981 part 5. Reduce the amount of time spent calling GetBindingParent(). r=smaug 2012-03-22 00:10:51 -04:00
Hessam Salehi
2bda7efc98 Bug 474505 - Replace uses of nsVoidPtrHashkey with nsPtrHashKey<T>; r=bsmedberg 2012-03-21 14:07:31 -04:00
Mark Capella
8721036540 Bug 734023 - Remove language arguments from nsIScriptGlobalObject methods, r=jst, f=ms2ger 2012-03-23 18:13:29 +01:00
Igor Bukanov
c8154dcd0e bug 730221 - delegating serialization of script principals to the embedding. r=:luke,:bz
Currently to serialize principals stored in JSScript we have a rather complex
schema. First there is the transcode callback that the embedding must provide
to transcode principals using XDR API. Second we use rather complex glue code
to implement that callback in terms of writing/reading nsIObjectOutputStream/
nsIObjectInputStream. This glue code is duplicated in 3 places. All this can
be avoided if we simply delegate transcoding of principals to the caller. In
addition, at least in the case of the cached startup scripts we do not even
need to transcode the principals as the the cached scripts always have the
system principal so we can skip all the transcode complexity there.

The patch implemnts this idea. In particular, the code in JS engine
responsible for transcoding of principals is replaced by the single API
function JS_XDRSetPrincipals that the embedding can use to set principals for
decoded scripts and functions. Then the startup cache uses this to set the
principals for the decoded script to the system principals. The other two
places in nsJSContext::Serialize and  XBL_SerializeFunction that need to
serialize principals together with a function or script now uses common
utilities in nsXPConnect so the serialization complexity resides in the single
 place.
2012-02-13 14:10:04 +01:00
Andrew McCreight
071b58d7ff Bug 735550 - unmark gray objects held by live nsXBLDocGlobalObjects. r=smaug 2012-03-18 07:17:05 -07:00
Nathan Froyd
70907fb5f2 Bug 732167 - Eliminate duplicate headers in content. r=mounir 2012-03-06 13:55:37 -05:00
Blake Kaplan
662d0db31b Bug 727884 - Make nsWrapperCache::WrapObject take a JSObject scope instead of XPCWrappedNativeScope. r=peterv 2012-03-14 16:25:40 +01:00
Emanuel Hoogeveen
bdce617c30 Bug 492931 - Fix case conversion in a bunch of DOM functions to only convert ASCII characters. r=sicking,khuey 2012-03-09 21:50:34 -08:00
Adam
868e790488 Make "let" a reserved word for Web scripts. Bug 730139, r=jorendorff. 2012-03-02 18:28:29 -06:00
Nathan Froyd
e6e610c92e Bug 730825 - Part 1: change content/ to use nsTHashtable instead of nsDoubleHashtable; r=sicking 2012-02-29 11:28:01 -05:00
David Mandelin
3588ac5aae Bug 730511: remove obsolete typedefs intN, uintN, r=luke 2012-02-28 15:11:11 -08:00
Igor Bukanov
1013be2159 bug 726944 - Remove JSClass::xdrObject and related functionality. r=luke 2012-02-13 09:02:21 +01:00
Neil Deakin
4fcce60342 Bug 723676, crash writing to startup cache when an empty method body is used, r=bz 2012-02-13 14:24:28 -05:00
Neil Deakin
ba93add056 Bug 721452, crash writing to startup cache when empty handler is used, r=bz 2012-02-13 14:24:28 -05:00
Olli Pettay
fee84b90ca Bug 725752 - BBP for XBL protos, f=mccr8,r=jst 2012-02-11 13:04:28 +02:00
Igor Bukanov
3638c8cf65 bug 724310 - drop cx argument from JSObject field and fixed slots infallible API. r=:Waldo
--HG--
extra : rebase_source : b78519db2ff008eb5143676d2db47935f0e89f45
2012-02-05 21:07:23 +01:00
Igor Bukanov
55704654e7 backout merge for bug 724310. r=irc 2012-02-09 21:28:22 +01:00
Igor Bukanov
ca990d2064 bug 723517 - drop cx argument from JSObject field and fixed slots infallible API. r=:Waldo
--HG--
extra : rebase_source : c461dfc0e0e0462ab262cc01c2a771d3bb0971cc
2012-02-05 21:07:23 +01:00
Olli Pettay
e14df23427 Bug 724284, cleanup XBL proto setup, r=bz 2012-02-07 10:35:58 +02:00
Panagiotis Koutsourakis
9c7dfb9706 Bug 702388 - Convert Makefiles to use |TEST_DIRS += foo| r=khuey
Files named Makefile.in containing the expression

DIRS += <foo>
or
DIRS = <foo>

inside the conditional expression

ifdef ENABLE_TESTS
...
endif

are changed to

TEST_DIRS += tests

outside any conditional expression.

The files

./layout/Makefile.in
./layout/Makefile.in
./layout/style/Makefile.in
./rdf/Makefile.in
./security/manager/Makefile.in
./content/Makefile.in
./content/smil/Makefile.in
./content/xul/templates/Makefile.in
./content/xul/content/Makefile.in
./content/base/Makefile.in
./content/media/Makefile.in
./parser/htmlparser/Makefile.in
./dom/sms/Makefile.in
./js/jsd/Makefile.in
./js/xpconnect/Makefile.in
./widget/Makefile.in
./widget/windows/Makefile.in
./Makefile.in
./startupcache/Makefile.in
./storage/Makefile.in
./gfx/Makefile.in
./intl/strres/Makefile.in
./intl/uconv/Makefile.in
./intl/unicharutil/Makefile.in
./intl/lwbrk/Makefile.in
./embedding/Makefile.in
./modules/libjar/Makefile.in
./modules/libpref/Makefile.in
./build/Makefile.in
./build/win32/Makefile.in
./xpcom/Makefile.in
./extensions/spellcheck/hunspell/Makefile.in
./extensions/cookie/Makefile.in
./netwerk/Makefile.in
./netwerk/streamconv/Makefile.in
./editor/txmgr/Makefile.in
./toolkit/mozapps/shared/Makefile.in
./toolkit/mozapps/update/Makefile.in
./toolkit/library/Makefile.in
./toolkit/library/Makefile.in
./toolkit/crashreporter/Makefile.in
./toolkit/components/perf/Makefile.in
./toolkit/components/perf/Makefile.in
./toolkit/components/feeds/Makefile.in
./toolkit/components/url-classifier/Makefile.in

contain the string

ifdef ENABLE_TESTS

but have some other statement inside (e.g. TOOL_DIRS += <foo> etc) and
they remain unchanged by this patch.
2012-02-04 17:32:24 +00:00
Igor Bukanov
17db9a067b bug 723517 - Drop cx argumrent from JS_GetClass(cx, obj). r=luke 2012-02-04 01:54:57 +01:00
Andrew McCreight
821eb101a0 Bug 720292 - add more cycle collector edge names. r=smaug 2012-01-23 15:25:53 -08:00
Ms2ger
4e6b2dedac Bug 717195 - Export dombindings.h; r=bholley 2012-01-15 09:13:12 +01:00
Ms2ger
e868830132 Bug 717216 - Don't return nsnull from nsXBLDocGlobalObject::EnsureScriptEnvironment; r=volkmar 2012-01-15 09:13:11 +01:00
Olli Pettay
f00c463259 Bug 716004 - Traverse nsXBLDocumentInfo less often, r=jst,mccr8 2012-01-13 14:44:14 +02:00
Ehsan Akhgari
1370e54569 Bug 716677 - test_bug296375.xul makes incorrect assumptions about the event ordering; r=smaug 2012-01-10 12:42:47 -05:00
Olli Pettay
fb75702799 Bug 713865 - Don't traverse XBL and XUL protos so much, r=bent 2011-12-29 16:34:05 +02:00