gecko/dom/base
Igor Bukanov fbeb82e29f 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
..
crashtests Back out 570dd369e02a, bc777c65c5ca and 12a483042e9a to fix bustage 2012-01-27 15:34:30 +01:00
test Bug 722626: Implement DOMRequest object. r=mrbkap 2012-02-24 14:19:49 +01:00
ConsoleAPI.js Bug 611032 - Errors from before the Web Console is opened do not show. r=gavin.sharp,rcampbell f=rcampbell 2012-01-11 12:51:49 +02:00
ConsoleAPI.manifest
ConsoleAPIStorage.jsm Bug 611032 - Errors from before the Web Console is opened do not show. r=gavin.sharp,rcampbell f=rcampbell 2012-01-11 12:51:49 +02:00
domerr.msg Bug 711047 Part 2 - Remove RangeException in favor of DOMException. r=sicking 2012-03-01 13:35:48 -05:00
DOMError.cpp Bug 705640 - Implement DOMError as defined in DOM 4, r=mounir. 2012-01-24 02:13:41 -08:00
DOMError.h Bug 705640 - Implement DOMError as defined in DOM 4, r=mounir. 2012-01-24 02:13:41 -08:00
DOMRequest.cpp Bug 734057 - Make nsDOMEventTargetHelper to not have strong pointer to window, r=jst,bent 2012-03-13 02:56:07 +02:00
DOMRequest.h Bug 722626: Implement DOMRequest object. r=mrbkap 2012-02-24 14:19:49 +01:00
DOMRequestHelper.jsm Bug 720415 - update navigator.mozApps m-c implementation - DOM + repo [r=gwagner] 2012-03-06 11:50:58 -08:00
Makefile.in Bug 720794 - Part 1 (HAL) - Implement reading and event parts of Screen Orientation API. r=cjones 2012-03-13 17:42:46 +01:00
Navigator.cpp Bug 697132 - Use nsCOMPtr constructor. r=Ms2ger 2012-03-14 18:00:29 -04:00
Navigator.h Bug 711601 - B2G Bluetooth Boiler Plate r=bent 2012-02-20 16:15:19 +01:00
nsBarProps.cpp Bug 713747 - Remove usage of UniversalFoo in gecko. r=bz 2011-12-30 09:35:39 -08:00
nsBarProps.h
nsContentPermissionHelper.cpp
nsContentPermissionHelper.h
nsDOMCID.h
nsDOMClassInfo.cpp Bug 735261 - navigator.mozConnection should be an instance of EventTarget. r=smaug 2012-03-14 19:50:11 +01:00
nsDOMClassInfo.h Fix for bug 732175 (Generate DOM list bindings that aren't controlled by the dom.new_bindings pref and remove old bindings for NodeList/HTMLCollection/HTMLOptionsCollection). r=jst. 2012-02-27 18:02:47 +01:00
nsDOMClassInfoClasses.h Bug 550309 - Part c: Implement ImageData; r=bz 2012-03-16 10:44:08 +01:00
nsDOMClassInfoID.h Bug 550309 - Part d: Try unwrapping to nsIDOMImageData in GetImageData(); r=bz 2012-03-16 10:44:39 +01:00
nsDOMError.h Bug 711047 Part 2 - Remove RangeException in favor of DOMException. r=sicking 2012-03-01 13:35:48 -05:00
nsDOMException.cpp Bug 711047 Part 2 - Remove RangeException in favor of DOMException. r=sicking 2012-03-01 13:35:48 -05:00
nsDOMException.h Bug 711047 Part 2 - Remove RangeException in favor of DOMException. r=sicking 2012-03-01 13:35:48 -05:00
nsDOMJSUtils.h Bug 734481 - Make nsIJSArgArray inherit from nsIArray; r=jst 2012-03-11 09:53:05 +01:00
nsDOMNavigationTiming.cpp
nsDOMNavigationTiming.h
nsDOMScriptObjectFactory.cpp Bug 711047 Part 2 - Remove RangeException in favor of DOMException. r=sicking 2012-03-01 13:35:48 -05:00
nsDOMScriptObjectFactory.h
nsDOMScriptObjectHolder.h Bug 698420 - Make nsScriptObjectHolder typesafe; r=bz 2011-12-18 11:05:12 +01:00
nsDOMString.h
nsDOMWindowList.cpp
nsDOMWindowList.h
nsDOMWindowUtils.cpp Bug 732091 - Part 2: Add {set,get}IsFirstPaint to nsIDOMWindowUtils and nsIPresShell. r=ehsan 2012-03-12 11:50:11 -04:00
nsDOMWindowUtils.h
nsFocusManager.cpp Backed out changeset 2cd01fd07ce8 2012-03-19 12:54:32 +01:00
nsFocusManager.h Bug 653230, add panels with focusable elements into the document tab navigation order, r=smaug 2012-02-23 16:02:33 -05:00
nsGlobalWindow.cpp Bug 735781 - Make sure nsScreen don't call RemoveObserver twice in a row. r=jlebar 2012-03-15 10:58:56 +01:00
nsGlobalWindow.h Bug 727884 - Make nsWrapperCache::WrapObject take a JSObject scope instead of XPCWrappedNativeScope. r=peterv 2012-03-14 16:25:40 +01:00
nsGlobalWindowCommands.cpp Bug 726968 - Fix some dom/ build warnings; r=mounir 2012-02-21 10:34:01 +01:00
nsGlobalWindowCommands.h
nsHistory.cpp Bug 664737 - Make GetNext use a belt as well as its braces. r=bzbarsky 2012-01-26 12:54:23 +01:00
nsHistory.h
nsIBaseDOMException.h
nsIDOMClassInfo.h
nsIDOMDOMError.idl Bug 705640 - Implement DOMError as defined in DOM 4, r=mounir. 2012-01-24 02:13:41 -08:00
nsIDOMDOMRequest.idl Bug 722626: Implement DOMRequest object. r=mrbkap 2012-02-24 14:19:49 +01:00
nsIDOMScriptObjectFactory.h
nsIEntropyCollector.idl
nsIJSEventListener.h Bug 723799 - Use mallocSizeOf in the DOM memory reporters. r=mounir. 2012-02-01 13:58:01 -08:00
nsIJSNativeInitializer.h
nsIScriptChannel.idl
nsIScriptContext.h Bug 734473 - Remove nsIScriptContext::FinalizeContext; r=jst 2012-03-11 09:51:22 +01:00
nsIScriptExternalNameSet.h
nsIScriptGlobalObject.h Bug 720808 - Add nsJSEventListener and nsGlobalWndow to BBP, r=mccr8 2012-01-26 16:03:21 +01:00
nsIScriptGlobalObjectOwner.h
nsIScriptNameSpaceManager.h
nsIScriptObjectOwner.h Bug 698420 - Make nsScriptObjectHolder typesafe; r=bz 2011-12-18 11:05:12 +01:00
nsIScriptObjectPrincipal.h
nsIScriptRuntime.h
nsIScriptTimeoutHandler.h Bug 394769. Remove the additional lateness argument for timeouts and intervals. r=jst 2012-02-07 15:28:08 -05:00
nsJSEnvironment.cpp bug 730221 - delegating serialization of script principals to the embedding. r=:luke,:bz 2012-02-13 14:10:04 +01:00
nsJSEnvironment.h Bug 735014 - Wait longer for PAGE_HIDE GCs (r=smaug) 2012-03-12 16:25:03 -07:00
nsJSTimeoutHandler.cpp Bug 734481 - Make nsIJSArgArray inherit from nsIArray; r=jst 2012-03-11 09:53:05 +01:00
nsJSUtils.cpp bug 724310 - drop cx argument from JSObject field and fixed slots infallible API. r=:Waldo 2012-02-05 21:07:23 +01:00
nsJSUtils.h
nsLocation.cpp
nsLocation.h
nsMimeTypeArray.cpp Fixing bug 690952. Move window.navigator from the outer window to the inner window, and stop persisting it across same origin page navigations. r=mrbkap@gmail.com 2011-12-01 00:28:16 -08:00
nsMimeTypeArray.h Fixing bug 690952. Move window.navigator from the outer window to the inner window, and stop persisting it across same origin page navigations. r=mrbkap@gmail.com 2011-12-01 00:28:16 -08:00
nsPerformance.cpp
nsPerformance.h
nsPIDOMWindow.h Bug 727303 - Add nsPIDOMWindow::SetFullScreenInteral. r=roc 2012-02-20 10:02:08 +13:00
nsPIWindowRoot.h
nsPluginArray.cpp Fixing bug 690952. Move window.navigator from the outer window to the inner window, and stop persisting it across same origin page navigations. r=mrbkap@gmail.com 2011-12-01 00:28:16 -08:00
nsPluginArray.h Fixing bug 690952. Move window.navigator from the outer window to the inner window, and stop persisting it across same origin page navigations. r=mrbkap@gmail.com 2011-12-01 00:28:16 -08:00
nsQueryContentEventResult.cpp
nsQueryContentEventResult.h
nsScreen.cpp Bug 735781 - Make sure nsScreen don't call RemoveObserver twice in a row. r=jlebar 2012-03-15 10:58:56 +01:00
nsScreen.h Bug 720799 - Don't use mDocShell in nsScreen. r=jst,jlebar 2012-03-14 19:14:53 +01:00
nsScriptNameSpaceManager.cpp Bug 729940 - Part 2: Stop using crappy hash functions in Gecko. r=bz 2012-03-12 18:53:18 -04:00
nsScriptNameSpaceManager.h
nsStructuredCloneContainer.cpp Bug 714332 - Fix uint64 types usage in dom/workers and dom/base; r=bent 2012-01-02 19:08:14 +01:00
nsStructuredCloneContainer.h Bug 708735 - Use <stdint.h> types in JSAPI and throughout SpiderMonkey. Continue to provide the {u,}int{8,16,32,64} and JS{Uint,Int}{8,16,32,64} integer types through a single header, however, for a simpler backout strategy -- and also to ease the transition for embedders. r=timeless on switching the jsd API to use the <stdint.h> types, r=luke, r=dmandelin 2011-12-08 22:54:10 -05:00
nsWindowMemoryReporter.cpp Bug 713799 - Rearrange the "window-objects" sub-tree in about:memory to make per-tab memory usage more obvious. r=jst. 2012-03-12 23:00:18 -07:00
nsWindowMemoryReporter.h Bug 730181 (part 2) - Rename nsDOMMemoryReporter. r=khuey. 2012-02-23 18:43:33 -08:00
nsWindowRoot.cpp
nsWindowRoot.h
nsWrapperCache.h Bug 727884 - Make nsWrapperCache::WrapObject take a JSObject scope instead of XPCWrappedNativeScope. r=peterv 2012-03-14 16:25:40 +01:00
nsWrapperCacheInlines.h Fix for bug 736229 (Stop storing expando objects in the wrapper cache, store the proxy instead). r=jst. 2012-03-14 15:22:10 +01:00
ScreenOrientation.h Bug 720794 - Part 1 (HAL) - Implement reading and event parts of Screen Orientation API. r=cjones 2012-03-13 17:42:46 +01:00
StructuredCloneTags.h Bug 661877 - Enable storing files in IndexedDB. r=bent 2011-12-16 08:34:24 +01:00
Webapps.js Bug 732982 - Expose a wifi API to the DOM. The API is very much a work in progress and will change soon. r=cjones/fabrice/vigntetun DONTBUILD 2012-03-14 21:39:15 +01:00
Webapps.jsm Bug 735109 - unregister message listeners on shutdown in Webapps.jsm [r=felipe] 2012-03-12 17:33:10 -07:00
Webapps.manifest Bug 720415 - update navigator.mozApps m-c implementation - DOM + repo [r=gwagner] 2012-03-06 11:50:58 -08:00