Bug 1733980 - Remove vestiges of removed ***Layer class. r=gfx-reviewers,mattwoodrow

Differential Revision: https://phabricator.services.mozilla.com/D127464
This commit is contained in:
Tetsuharu Ohzeki
2021-10-04 22:19:11 +00:00
parent 8de9c4e549
commit 0037073bad
10 changed files with 1 additions and 94 deletions

View File

@@ -58,12 +58,9 @@ namespace layers {
class AsyncPanZoomController;
class ClientLayerManager;
class Layer;
class PaintedLayer;
class ContainerLayer;
class ColorLayer;
class CompositorBridgeChild;
class ReadbackProcessor;
class HostLayer;
class FocusTarget;
class KnowsCompositor;
class TransactionIdAllocator;
@@ -171,56 +168,6 @@ class LayerManager : public WindowRenderer {
GetUserData(&gLayerManagerLayerBuilder));
}
/**
* Function called to draw the contents of each PaintedLayer.
* aRegionToDraw contains the region that needs to be drawn.
* This would normally be a subregion of the visible region.
* The callee must draw all of aRegionToDraw. Drawing outside
* aRegionToDraw will be clipped out or ignored.
* The callee must draw all of aRegionToDraw.
* This region is relative to 0,0 in the PaintedLayer.
*
* aDirtyRegion should contain the total region that is be due to be painted
* during the transaction, even though only aRegionToDraw should be drawn
* during this call. aRegionToDraw must be entirely contained within
* aDirtyRegion. If the total dirty region is unknown it is okay to pass a
* subregion of the total dirty region, e.g. just aRegionToDraw, though it
* may not be as efficient.
*
* aRegionToInvalidate contains a region whose contents have been
* changed by the layer manager and which must therefore be invalidated.
* For example, this could be non-empty if a retained layer internally
* switches from RGBA to RGB or back ... we might want to repaint it to
* consistently use subpixel-AA or not.
* This region is relative to 0,0 in the PaintedLayer.
* aRegionToInvalidate may contain areas that are outside
* aRegionToDraw; the callee must ensure that these areas are repainted
* in the current layer manager transaction or in a later layer
* manager transaction.
*
* aContext must not be used after the call has returned.
* We guarantee that buffered contents in the visible
* region are valid once drawing is complete.
*
* The origin of aContext is 0,0 in the PaintedLayer.
*/
typedef void (*DrawPaintedLayerCallback)(
PaintedLayer* aLayer, gfxContext* aContext,
const nsIntRegion& aRegionToDraw, const nsIntRegion& aDirtyRegion,
DrawRegionClip aClip, const nsIntRegion& aRegionToInvalidate,
void* aCallbackData);
/**
* Finish the construction phase of the transaction, perform the
* drawing phase, and end the transaction.
* During the drawing phase, all PaintedLayers in the tree are
* drawn in tree order, exactly once each, except for those layers
* where it is known that the visible region is empty.
*/
virtual void EndTransaction(DrawPaintedLayerCallback aCallback,
void* aCallbackData,
EndTransactionFlags aFlags = END_DEFAULT) = 0;
/**
* Schedule a composition with the remote Compositor, if one exists
* for this LayerManager. Useful in conjunction with the
@@ -263,29 +210,6 @@ class LayerManager : public WindowRenderer {
virtual void Mutated(Layer* aLayer) {}
virtual void MutatedSimple(Layer* aLayer) {}
/**
* Hints that can be used during PaintedLayer creation to influence the type
* or properties of the layer created.
*
* NONE: No hint.
* SCROLLABLE: This layer may represent scrollable content.
*/
enum PaintedLayerCreationHint { NONE, SCROLLABLE };
/**
* CONSTRUCTION PHASE ONLY
* Create a PaintedLayer for this manager's layer tree.
*/
virtual already_AddRefed<PaintedLayer> CreatePaintedLayer() = 0;
/**
* CONSTRUCTION PHASE ONLY
* Create a PaintedLayer for this manager's layer tree, with a creation hint
* parameter to help optimise the type of layer created.
*/
virtual already_AddRefed<PaintedLayer> CreatePaintedLayerWithHint(
PaintedLayerCreationHint) {
return CreatePaintedLayer();
}
/**
* CONSTRUCTION PHASE ONLY
* Create a ContainerLayer for this manager's layer tree.

View File

@@ -33,7 +33,7 @@
#include "mozilla/gfx/UserData.h" // for UserData, UserDataKey (ptr only)
#include "mozilla/layers/AnimationInfo.h" // for AnimationInfo
#include "mozilla/layers/LayerAttributes.h" // for SimpleLayerAttributes, ScrollbarData (ptr only)
#include "mozilla/layers/LayerManager.h" // for LayerManager, LayerManager::PaintedLayerCreationHint
#include "mozilla/layers/LayerManager.h" // for LayerManager
#include "mozilla/layers/ScrollableLayerGuid.h" // for ScrollableLayerGuid, ScrollableLayerGuid::ViewID
#include "mozilla/layers/BSPTree.h"
#include "nsISupports.h" // for NS_INLINE_DECL_REFCOUNTING
@@ -64,7 +64,6 @@ namespace layers {
class Animation;
class AsyncPanZoomController;
class PaintedLayer;
class ContainerLayer;
class CompositorAnimations;
class SpecificLayerAttributes;

View File

@@ -25,7 +25,6 @@ class DrawTarget;
namespace layers {
class CopyableCanvasLayer;
class TextureClient;
/**

View File

@@ -16,7 +16,6 @@ namespace mozilla {
namespace layers {
class ContainerLayer;
class PaintedLayer;
class ReadbackProcessor {
public:

View File

@@ -38,8 +38,6 @@ class DrawTarget;
namespace layers {
class PaintedLayer;
/**
* A compositable client for PaintedLayers. These are different to Image/Canvas
* clients due to sending a valid region across IPC and because we do a lot more

View File

@@ -270,7 +270,6 @@ void ImageClientSingle::OnDetach() { mBuffers.Clear(); }
ImageClient::ImageClient(CompositableForwarder* aFwd, TextureFlags aFlags,
CompositableType aType)
: CompositableClient(aFwd, aFlags),
mLayer(nullptr),
mType(aType),
mLastUpdateGenerationCounter(0) {}

View File

@@ -26,7 +26,6 @@ namespace layers {
class CompositableForwarder;
class Image;
class ImageContainer;
class ShadowableLayer;
class ImageClientSingle;
/**
@@ -55,9 +54,6 @@ class ImageClient : public CompositableClient {
virtual bool UpdateImage(ImageContainer* aContainer,
uint32_t aContentFlags) = 0;
void SetLayer(ShadowableLayer* aLayer) { mLayer = aLayer; }
ShadowableLayer* GetLayer() const { return mLayer; }
/**
* asynchronously remove all the textures used by the image client.
*
@@ -81,7 +77,6 @@ class ImageClient : public CompositableClient {
ImageClient(CompositableForwarder* aFwd, TextureFlags aFlags,
CompositableType aType);
ShadowableLayer* mLayer;
CompositableType mType;
uint32_t mLastUpdateGenerationCounter;
};

View File

@@ -48,9 +48,6 @@ class TestLayerManager : public LayerManager {
const nsCString& = nsCString()) {
return true;
}
virtual void EndTransaction(DrawPaintedLayerCallback aCallback,
void* aCallbackData,
EndTransactionFlags aFlags = END_DEFAULT) {}
virtual int32_t GetMaxTextureSize() const { return 0; }
};

View File

@@ -36,7 +36,6 @@ class nsDisplayImage;
class PresShell;
namespace layers {
class ImageContainer;
class ImageLayer;
class LayerManager;
} // namespace layers
} // namespace mozilla
@@ -66,7 +65,6 @@ class nsImageFrame : public nsAtomicContainerFrame, public nsIReflowCallback {
typedef mozilla::image::ImgDrawResult ImgDrawResult;
typedef mozilla::layers::ImageContainer ImageContainer;
typedef mozilla::layers::ImageLayer ImageLayer;
typedef mozilla::layers::LayerManager LayerManager;
NS_DECL_FRAMEARENA_HELPERS(nsImageFrame)

View File

@@ -86,7 +86,6 @@ namespace layers {
struct FrameMetrics;
class RenderRootStateManager;
class Layer;
class ImageLayer;
class ImageContainer;
class StackingContextHelper;
class WebRenderScrollData;