mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-13 13:25:37 +00:00
Bug 888622 - Root layer isn't always ContainerLayer, remove incorrect cast. r=kats
--HG-- extra : rebase_source : c3948e30b6fd05c896e1a773e520b8eecfdd05af
This commit is contained in:
parent
075841615e
commit
9270c725b9
@ -343,7 +343,7 @@ LayerTransactionParent::RecvUpdate(const InfallibleTArray<Edit>& cset,
|
||||
case Edit::TOpSetRoot: {
|
||||
MOZ_LAYERS_LOG(("[ParentSide] SetRoot"));
|
||||
|
||||
mRoot = AsLayerComposite(edit.get_OpSetRoot())->AsContainer();
|
||||
mRoot = AsLayerComposite(edit.get_OpSetRoot())->AsLayer();
|
||||
break;
|
||||
}
|
||||
case Edit::TOpInsertAfter: {
|
||||
|
@ -44,7 +44,7 @@ public:
|
||||
LayerManagerComposite* layer_manager() const { return mLayerManager; }
|
||||
|
||||
uint64_t GetId() const { return mId; }
|
||||
ContainerLayer* GetRoot() const { return mRoot; }
|
||||
Layer* GetRoot() const { return mRoot; }
|
||||
|
||||
// ISurfaceAllocator
|
||||
virtual bool AllocShmem(size_t aSize,
|
||||
@ -101,7 +101,7 @@ private:
|
||||
ShadowLayersManager* mShadowLayersManager;
|
||||
// Hold the root because it might be grafted under various
|
||||
// containers in the "real" layer tree
|
||||
nsRefPtr<ContainerLayer> mRoot;
|
||||
nsRefPtr<Layer> mRoot;
|
||||
// When this is nonzero, it refers to a layer tree owned by the
|
||||
// compositor thread. It is always true that
|
||||
// mId != 0 => mRoot == null
|
||||
|
@ -428,7 +428,7 @@ BuildViewMap(ViewMap& oldContentViews, ViewMap& newContentViews,
|
||||
|
||||
static void
|
||||
BuildBackgroundPatternFor(ContainerLayer* aContainer,
|
||||
ContainerLayer* aShadowRoot,
|
||||
Layer* aShadowRoot,
|
||||
const ViewConfig& aConfig,
|
||||
const gfxRGBA& aColor,
|
||||
LayerManager* aManager,
|
||||
@ -733,7 +733,7 @@ RenderFrameParent::BuildLayer(nsDisplayListBuilder* aBuilder,
|
||||
mContainer->SetInheritedScale(1.0f, 1.0f);
|
||||
}
|
||||
|
||||
ContainerLayer* shadowRoot = GetRootLayer();
|
||||
Layer* shadowRoot = GetRootLayer();
|
||||
if (!shadowRoot) {
|
||||
mContainer = nullptr;
|
||||
return nullptr;
|
||||
@ -930,7 +930,7 @@ RenderFrameParent::GetLayerTreeId() const
|
||||
return mLayersId;
|
||||
}
|
||||
|
||||
ContainerLayer*
|
||||
Layer*
|
||||
RenderFrameParent::GetRootLayer() const
|
||||
{
|
||||
LayerTransactionParent* shadowLayers = GetShadowLayers();
|
||||
@ -951,7 +951,7 @@ RenderFrameParent::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
||||
nsRect bounds = aFrame->EnsureInnerView()->GetBounds() + offset;
|
||||
clipState.ClipContentDescendants(bounds);
|
||||
|
||||
ContainerLayer* container = GetRootLayer();
|
||||
Layer* container = GetRootLayer();
|
||||
if (aBuilder->IsForEventDelivery() && container) {
|
||||
ViewTransform offset =
|
||||
ViewTransform(GetContentRectLayerOffset(aFrame, aBuilder));
|
||||
|
@ -122,7 +122,7 @@ private:
|
||||
|
||||
LayerTransactionParent* GetShadowLayers() const;
|
||||
uint64_t GetLayerTreeId() const;
|
||||
ContainerLayer* GetRootLayer() const;
|
||||
Layer* GetRootLayer() const;
|
||||
|
||||
// When our child frame is pushing transactions directly to the
|
||||
// compositor, this is the ID of its layer tree in the compositor's
|
||||
|
Loading…
Reference in New Issue
Block a user