1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/gfx/layers/ipc/ShadowLayerParent.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,58 @@ 1.4 +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- 1.5 + * vim: sw=2 ts=8 et : 1.6 + */ 1.7 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.8 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.9 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.10 + 1.11 +#ifndef mozilla_layers_ShadowLayerParent_h 1.12 +#define mozilla_layers_ShadowLayerParent_h 1.13 + 1.14 +#include "mozilla/Attributes.h" // for MOZ_OVERRIDE 1.15 +#include "mozilla/ipc/ProtocolUtils.h" 1.16 +#include "mozilla/layers/PLayerParent.h" // for PLayerParent 1.17 +#include "nsAutoPtr.h" // for nsRefPtr 1.18 + 1.19 +namespace mozilla { 1.20 +namespace layers { 1.21 + 1.22 +class ContainerLayer; 1.23 +class Layer; 1.24 +class LayerManager; 1.25 + 1.26 +class CanvasLayerComposite; 1.27 +class ColorLayerComposite; 1.28 +class ContainerLayerComposite; 1.29 +class ImageLayerComposite; 1.30 +class RefLayerComposite; 1.31 +class ThebesLayerComposite; 1.32 + 1.33 +class ShadowLayerParent : public PLayerParent 1.34 +{ 1.35 +public: 1.36 + ShadowLayerParent(); 1.37 + 1.38 + virtual ~ShadowLayerParent(); 1.39 + 1.40 + void Bind(Layer* layer); 1.41 + void Destroy(); 1.42 + 1.43 + Layer* AsLayer() const { return mLayer; } 1.44 + 1.45 + ContainerLayerComposite* AsContainerLayerComposite() const; 1.46 + CanvasLayerComposite* AsCanvasLayerComposite() const; 1.47 + ColorLayerComposite* AsColorLayerComposite() const; 1.48 + ImageLayerComposite* AsImageLayerComposite() const; 1.49 + RefLayerComposite* AsRefLayerComposite() const; 1.50 + ThebesLayerComposite* AsThebesLayerComposite() const; 1.51 + 1.52 +private: 1.53 + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; 1.54 + 1.55 + nsRefPtr<Layer> mLayer; 1.56 +}; 1.57 + 1.58 +} // namespace layers 1.59 +} // namespace mozilla 1.60 + 1.61 +#endif // ifndef mozilla_layers_ShadowLayerParent_h