Bug 1148949 - Apply async properties when querying the animated transform for cross-process compositor parents too; r=mattwoodrow

Bug 1113425 (specifically, part 2:
https://hg.mozilla.org/mozilla-central/rev/bb3866dea03e) introduced a fix for
a race condition that occurs when querying the animated transform of a layer.
However, that fix failed to update CrossProcessCompositorParent and hence the
issue still arises when e10s is enabled.

This patch applies the fix from that bug to CrossProcessCompositorParent.
This commit is contained in:
Brian Birtles 2015-04-21 12:00:33 +09:00
Родитель eeb2174b40
Коммит 52dd19f8a0
2 изменённых файлов: 19 добавлений и 1 удалений

Просмотреть файл

@ -1648,6 +1648,8 @@ public:
virtual bool SetTestSampleTime(LayerTransactionParent* aLayerTree,
const TimeStamp& aTime) override;
virtual void LeaveTestMode(LayerTransactionParent* aLayerTree) override;
virtual void ApplyAsyncProperties(LayerTransactionParent* aLayerTree)
override;
virtual void GetAPZTestData(const LayerTransactionParent* aLayerTree,
APZTestData* aOutData) override;
virtual void SetConfirmedTargetAPZC(const LayerTransactionParent* aLayerTree,
@ -2025,6 +2027,22 @@ CrossProcessCompositorParent::LeaveTestMode(LayerTransactionParent* aLayerTree)
state->mParent->LeaveTestMode(aLayerTree);
}
void
CrossProcessCompositorParent::ApplyAsyncProperties(
LayerTransactionParent* aLayerTree)
{
uint64_t id = aLayerTree->GetId();
MOZ_ASSERT(id != 0);
const CompositorParent::LayerTreeState* state =
CompositorParent::GetIndirectShadowTree(id);
if (!state) {
return;
}
MOZ_ASSERT(state->mParent);
state->mParent->ApplyAsyncProperties(aLayerTree);
}
void
CrossProcessCompositorParent::GetAPZTestData(const LayerTransactionParent* aLayerTree,
APZTestData* aOutData)

Просмотреть файл

@ -35,7 +35,7 @@ public:
virtual bool SetTestSampleTime(LayerTransactionParent* aLayerTree,
const TimeStamp& aTime) { return true; }
virtual void LeaveTestMode(LayerTransactionParent* aLayerTree) { }
virtual void ApplyAsyncProperties(LayerTransactionParent* aLayerTree) { }
virtual void ApplyAsyncProperties(LayerTransactionParent* aLayerTree) = 0;
virtual void GetAPZTestData(const LayerTransactionParent* aLayerTree,
APZTestData* aOutData) { }
virtual void SetConfirmedTargetAPZC(const LayerTransactionParent* aLayerTree,