Bug 1035833 - Fix layersId allocation in nested content process. r=mattwoodrow
author"Kan-Ru Chen (陳侃如)" <kanru@kanru.info>
Wed, 09 Jul 2014 16:42:04 +0800
changeset 193055 c125cf6a0a94c0b34b617c06d16e66780cdfa745
parent 193044 8d6c8b4d34c54d56eb60631331cba2006916bc2c
child 193056 6a56c14d382fde8155681ed53bcb47e2419925b6
push id27107
push userryanvm@gmail.com
push dateWed, 09 Jul 2014 19:45:31 +0000
treeherdermozilla-central@6db315bcdb6a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1035833
milestone33.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1035833 - Fix layersId allocation in nested content process. r=mattwoodrow
layout/ipc/RenderFrameParent.cpp
--- a/layout/ipc/RenderFrameParent.cpp
+++ b/layout/ipc/RenderFrameParent.cpp
@@ -733,17 +733,18 @@ RenderFrameParent::RenderFrameParent(nsF
 
   if (lm && lm->GetRoot() && lm->GetRoot()->AsContainerLayer()) {
     ViewID rootScrollId = lm->GetRoot()->AsContainerLayer()->GetFrameMetrics().GetScrollId();
     if (rootScrollId != FrameMetrics::NULL_SCROLL_ID) {
       mContentViews[rootScrollId] = new nsContentView(aFrameLoader, rootScrollId, true);
     }
   }
 
-  if (gfxPlatform::UsesOffMainThreadCompositing()) {
+  if (gfxPlatform::UsesOffMainThreadCompositing() &&
+      XRE_GetProcessType() == GeckoProcessType_Default) {
     // Our remote frame will push layers updates to the compositor,
     // and we'll keep an indirect reference to that tree.
     *aId = mLayersId = CompositorParent::AllocateLayerTreeId();
     if (lm && lm->GetBackendType() == LayersBackend::LAYERS_CLIENT) {
       ClientLayerManager *clientManager =
         static_cast<ClientLayerManager*>(lm.get());
       clientManager->GetRemoteRenderer()->SendNotifyChildCreated(mLayersId);
     }