Bug 941138 - Make the duplicated code paths consistent. r=botond
authorKartikaya Gupta <kgupta@mozilla.com>
Fri, 17 Jan 2014 09:53:08 -0500
changeset 163955 87aeba6685d4ea39244a83fa5c3611aa116e08df
parent 163954 cb989ceae01be259962228b1a7b54250dcb85775
child 163956 434780f5d0230921e64e17d85cfb6f5678b603aa
push id38592
push userkgupta@mozilla.com
push dateFri, 17 Jan 2014 14:53:22 +0000
treeherdermozilla-inbound@87aeba6685d4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbotond
bugs941138
milestone29.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 941138 - Make the duplicated code paths consistent. r=botond
gfx/layers/composite/APZCTreeManager.cpp
--- a/gfx/layers/composite/APZCTreeManager.cpp
+++ b/gfx/layers/composite/APZCTreeManager.cpp
@@ -322,20 +322,23 @@ APZCTreeManager::ReceiveInputEvent(const
           mApzcForInputBlock = CommonAncestor(mApzcForInputBlock.get(), apzc2.get());
           APZC_LOG("Using APZC %p as the common ancestor\n", mApzcForInputBlock.get());
           // For now, we only ever want to do pinching on the root APZC for a given layers id. So
           // when we find the common ancestor of multiple points, also walk up to the root APZC.
           mApzcForInputBlock = RootAPZCForLayersId(mApzcForInputBlock);
           APZC_LOG("Using APZC %p as the root APZC for multi-touch\n", mApzcForInputBlock.get());
         }
 
-        // Cache transformToApzc so it can be used for future events in this block.
         if (mApzcForInputBlock) {
+          // Cache transformToApzc so it can be used for future events in this block.
           GetInputTransforms(mApzcForInputBlock, transformToApzc, transformToGecko);
           mCachedTransformToApzcForInputBlock = transformToApzc;
+        } else {
+          // Reset the cached apz transform
+          mCachedTransformToApzcForInputBlock = gfx3DMatrix();
         }
       } else if (mApzcForInputBlock) {
         APZC_LOG("Re-using APZC %p as continuation of event block\n", mApzcForInputBlock.get());
       }
       if (mApzcForInputBlock) {
         mApzcForInputBlock->GetGuid(aOutTargetGuid);
         // Use the cached transform to compute the point to send to the APZC.
         // This ensures that the sequence of touch points an APZC sees in an