gfx/ipc/RemoteCompositorSession.h
author moz-wptsync-bot <wptsync@mozilla.com>
Thu, 08 Nov 2018 08:22:51 +0000
changeset 506788 f62150dda3664620284888933718cef568d96558
parent 465967 5d9f32557d7740c7c30f7bc6057c4de0c294d828
child 508163 6f3709b3878117466168c40affa7bca0b60cf75b
permissions -rw-r--r--
Bug 1505638 [wpt PR 13972] - Update wpt metadata, a=testonly wpt-pr: 13972 wpt-type: metadata

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef include_mozilla_gfx_ipc_RemoteCompositorSession_h
#define include_mozilla_gfx_ipc_RemoteCompositorSession_h

#include "CompositorSession.h"
#include "mozilla/gfx/Point.h"
#include "Units.h"

namespace mozilla {
namespace layers {

class RemoteCompositorSession final : public CompositorSession
{
public:
  RemoteCompositorSession(nsBaseWidget* aWidget,
                          CompositorBridgeChild* aChild,
                          CompositorWidgetDelegate* aWidgetDelegate,
                          APZCTreeManagerChild* aAPZ,
                          const LayersId& aRootLayerTreeId);
  ~RemoteCompositorSession() override;

  CompositorBridgeParent* GetInProcessBridge() const override;
  void SetContentController(GeckoContentController* aController) override;
  GeckoContentController* GetContentController();
  nsIWidget* GetWidget() const;
  RefPtr<IAPZCTreeManager> GetAPZCTreeManager() const override;
  void Shutdown() override;

  void NotifySessionLost();

private:
  nsBaseWidget* mWidget;
  RefPtr<APZCTreeManagerChild> mAPZ;
  RefPtr<GeckoContentController> mContentController;
};

} // namespace layers
} // namespace mozilla

#endif // include_mozilla_gfx_ipc_RemoteCompositorSession_h