Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3372)

Unified Diff: cc/test/fake_web_compositor_output_surface.h

Issue 11348371: cc: Move WebCompositorOutputSurface and related classes into cc/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: forlanding6 Created 8 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/fake_software_output_device.cc ('k') | cc/test/fake_web_compositor_software_output_device.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_web_compositor_output_surface.h
diff --git a/cc/test/fake_web_compositor_output_surface.h b/cc/test/fake_web_compositor_output_surface.h
deleted file mode 100644
index 3cd5b80fa8559053d6228af4ca6c115d56e0cd99..0000000000000000000000000000000000000000
--- a/cc/test/fake_web_compositor_output_surface.h
+++ /dev/null
@@ -1,76 +0,0 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CC_TEST_FAKE_WEB_COMPOSITOR_OUTPUT_SURFACE_H_
-#define CC_TEST_FAKE_WEB_COMPOSITOR_OUTPUT_SURFACE_H_
-
-#include "base/logging.h"
-#include "base/memory/scoped_ptr.h"
-#include "cc/test/fake_web_compositor_software_output_device.h"
-#include <public/WebCompositorOutputSurface.h>
-#include <public/WebGraphicsContext3D.h>
-
-namespace WebKit {
-
-class FakeWebCompositorOutputSurface : public WebCompositorOutputSurface {
-public:
- static inline scoped_ptr<FakeWebCompositorOutputSurface> create(scoped_ptr<WebGraphicsContext3D> context3D)
- {
- return make_scoped_ptr(new FakeWebCompositorOutputSurface(context3D.Pass()));
- }
-
- static inline scoped_ptr<FakeWebCompositorOutputSurface> createSoftware(scoped_ptr<WebCompositorSoftwareOutputDevice> softwareDevice)
- {
- return make_scoped_ptr(new FakeWebCompositorOutputSurface(softwareDevice.Pass()));
- }
-
- virtual bool bindToClient(WebCompositorOutputSurfaceClient* client) OVERRIDE
- {
- if (!m_context3D)
- return true;
- DCHECK(client);
- if (!m_context3D->makeContextCurrent())
- return false;
- m_client = client;
- return true;
- }
-
- virtual const Capabilities& capabilities() const OVERRIDE
- {
- return m_capabilities;
- }
-
- virtual WebGraphicsContext3D* context3D() const OVERRIDE
- {
- return m_context3D.get();
- }
- virtual WebCompositorSoftwareOutputDevice* softwareDevice() const OVERRIDE
- {
- return m_softwareDevice.get();
- }
-
- virtual void sendFrameToParentCompositor(const WebCompositorFrame&) OVERRIDE
- {
- }
-
-private:
- explicit FakeWebCompositorOutputSurface(scoped_ptr<WebGraphicsContext3D> context3D)
- {
- m_context3D = context3D.Pass();
- }
-
- explicit FakeWebCompositorOutputSurface(scoped_ptr<WebCompositorSoftwareOutputDevice> softwareDevice)
- {
- m_softwareDevice = softwareDevice.Pass();
- }
-
- scoped_ptr<WebGraphicsContext3D> m_context3D;
- scoped_ptr<WebCompositorSoftwareOutputDevice> m_softwareDevice;
- Capabilities m_capabilities;
- WebCompositorOutputSurfaceClient* m_client;
-};
-
-} // namespace WebKit
-
-#endif // CC_TEST_FAKE_WEB_COMPOSITOR_OUTPUT_SURFACE_H_
« no previous file with comments | « cc/test/fake_software_output_device.cc ('k') | cc/test/fake_web_compositor_software_output_device.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698