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

Unified Diff: ui/gfx/compositor/test/test_compositor_host_win.cc

Issue 10365007: ui: Move compositor/ directory out of gfx/, up to ui/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix DEPS Created 8 years, 8 months 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
Index: ui/gfx/compositor/test/test_compositor_host_win.cc
diff --git a/ui/gfx/compositor/test/test_compositor_host_win.cc b/ui/gfx/compositor/test/test_compositor_host_win.cc
deleted file mode 100644
index 62a05dd3444dd5fb71ccbdcb1ef5f80f8e529ee6..0000000000000000000000000000000000000000
--- a/ui/gfx/compositor/test/test_compositor_host_win.cc
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (c) 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.
-
-#include "ui/gfx/compositor/test/test_compositor_host.h"
-
-#include "base/compiler_specific.h"
-#include "base/memory/scoped_ptr.h"
-#include "ui/base/win/window_impl.h"
-#include "ui/gfx/compositor/compositor.h"
-
-namespace ui {
-
-class TestCompositorHostWin : public TestCompositorHost,
- public WindowImpl,
- public CompositorDelegate {
- public:
- TestCompositorHostWin(const gfx::Rect& bounds) {
- Init(NULL, bounds);
- compositor_.reset(new ui::Compositor(this, hwnd(), GetSize()));
- }
-
- virtual ~TestCompositorHostWin() {
- DestroyWindow(hwnd());
- }
-
- // Overridden from TestCompositorHost:
- virtual void Show() OVERRIDE {
- ShowWindow(hwnd(), SW_SHOWNORMAL);
- }
- virtual ui::Compositor* GetCompositor() OVERRIDE {
- return compositor_.get();
- }
-
- // Overridden from CompositorDelegate:
- virtual void ScheduleDraw() OVERRIDE {
- RECT rect;
- ::GetClientRect(hwnd(), &rect);
- InvalidateRect(hwnd(), &rect, FALSE);
- }
-
- private:
- BEGIN_MSG_MAP_EX(TestCompositorHostWin)
- MSG_WM_PAINT(OnPaint)
- END_MSG_MAP()
-
- void OnPaint(HDC dc) {
- compositor_->Draw(false);
- ValidateRect(hwnd(), NULL);
- }
-
- gfx::Size GetSize() {
- RECT r;
- GetClientRect(hwnd(), &r);
- return gfx::Rect(r).size();
- }
-
- scoped_ptr<ui::Compositor> compositor_;
-
- DISALLOW_COPY_AND_ASSIGN(TestCompositorHostWin);
-};
-
-TestCompositorHost* TestCompositorHost::Create(const gfx::Rect& bounds) {
- return new TestCompositorHostWin(bounds);
-}
-
-} // namespace ui
« no previous file with comments | « ui/gfx/compositor/test/test_compositor_host_mac.mm ('k') | ui/gfx/compositor/test/test_layer_animation_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698