Bug 1022167 - Ensure fence delivery of thebes layer in b2g process r=nical
authorSotaro Ikeda <sikeda@mozilla.com>
Wed, 18 Jun 2014 12:13:27 -0700
changeset 189463 7a45df366ec881993defb75e8574f8c6e0758d11
parent 189462 81a51de30a2a5ac43d3462afd0d4d8d9b9e32dc8
child 189464 157947d5fe31b8028f3d7c160d0e8f6aebb85841
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersnical
bugs1022167
milestone33.0a1
Bug 1022167 - Ensure fence delivery of thebes layer in b2g process r=nical
gfx/layers/client/CanvasClient.cpp
gfx/layers/client/ContentClient.cpp
--- a/gfx/layers/client/CanvasClient.cpp
+++ b/gfx/layers/client/CanvasClient.cpp
@@ -182,17 +182,17 @@ CanvasClientSurfaceStream::Update(gfx::I
       grallocTextureClient->SetTextureFlags(mTextureInfo.mTextureFlags);
       AddTextureClient(grallocTextureClient);
     }
 
     if (grallocTextureClient->GetIPDLActor()) {
       UseTexture(grallocTextureClient);
     }
 
-    if (mBuffer && CompositorChild::ChildProcessHasCompositor()) {
+    if (mBuffer) {
       // remove old buffer from CompositableHost
       RefPtr<AsyncTransactionTracker> tracker = new RemoveTextureFromCompositableTracker();
       // Hold TextureClient until transaction complete.
       tracker->SetTextureClient(mBuffer);
       mBuffer->SetRemoveFromCompositableTracker(tracker);
       // RemoveTextureFromCompositableAsync() expects CompositorChild's presence.
       GetForwarder()->RemoveTextureFromCompositableAsync(tracker, this, mBuffer);
     }
--- a/gfx/layers/client/ContentClient.cpp
+++ b/gfx/layers/client/ContentClient.cpp
@@ -366,27 +366,27 @@ ContentClientDoubleBuffered::DestroyFron
 void
 ContentClientDoubleBuffered::Updated(const nsIntRegion& aRegionToDraw,
                                      const nsIntRegion& aVisibleRegion,
                                      bool aDidSelfCopy)
 {
   ContentClientRemoteBuffer::Updated(aRegionToDraw, aVisibleRegion, aDidSelfCopy);
 
 #if defined(MOZ_WIDGET_GONK) && ANDROID_VERSION >= 17
-  if (mFrontClient && CompositorChild::ChildProcessHasCompositor()) {
+  if (mFrontClient) {
     // remove old buffer from CompositableHost
     RefPtr<AsyncTransactionTracker> tracker = new RemoveTextureFromCompositableTracker();
     // Hold TextureClient until transaction complete.
     tracker->SetTextureClient(mFrontClient);
     mFrontClient->SetRemoveFromCompositableTracker(tracker);
     // RemoveTextureFromCompositableAsync() expects CompositorChild's presence.
     GetForwarder()->RemoveTextureFromCompositableAsync(tracker, this, mFrontClient);
   }
 
-  if (mFrontClientOnWhite && CompositorChild::ChildProcessHasCompositor()) {
+  if (mFrontClientOnWhite) {
     // remove old buffer from CompositableHost
     RefPtr<AsyncTransactionTracker> tracker = new RemoveTextureFromCompositableTracker();
     // Hold TextureClient until transaction complete.
     tracker->SetTextureClient(mFrontClientOnWhite);
     mFrontClientOnWhite->SetRemoveFromCompositableTracker(tracker);
     // RemoveTextureFromCompositableAsync() expects CompositorChild's presence.
     GetForwarder()->RemoveTextureFromCompositableAsync(tracker, this, mFrontClientOnWhite);
   }