| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/ozone/platform/test/test_window_manager.h" | 5 #include "ui/ozone/platform/test/test_window_manager.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
| 9 #include "base/location.h" | 9 #include "base/location.h" |
| 10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 | 84 |
| 85 void TestWindowManager::RemoveWindow(int32_t window_id, TestWindow* window) { | 85 void TestWindowManager::RemoveWindow(int32_t window_id, TestWindow* window) { |
| 86 DCHECK_EQ(window, windows_.Lookup(window_id)); | 86 DCHECK_EQ(window, windows_.Lookup(window_id)); |
| 87 windows_.Remove(window_id); | 87 windows_.Remove(window_id); |
| 88 } | 88 } |
| 89 | 89 |
| 90 base::FilePath TestWindowManager::base_path() const { | 90 base::FilePath TestWindowManager::base_path() const { |
| 91 return location_; | 91 return location_; |
| 92 } | 92 } |
| 93 | 93 |
| 94 SurfaceFactoryOzone::HardwareState TestWindowManager::InitializeHardware() { | |
| 95 return INITIALIZED; | |
| 96 } | |
| 97 | |
| 98 void TestWindowManager::ShutdownHardware() { | |
| 99 } | |
| 100 | |
| 101 scoped_ptr<SurfaceOzoneCanvas> TestWindowManager::CreateCanvasForWidget( | 94 scoped_ptr<SurfaceOzoneCanvas> TestWindowManager::CreateCanvasForWidget( |
| 102 gfx::AcceleratedWidget widget) { | 95 gfx::AcceleratedWidget widget) { |
| 103 TestWindow* window = windows_.Lookup(widget); | 96 TestWindow* window = windows_.Lookup(widget); |
| 104 DCHECK(window); | 97 DCHECK(window); |
| 105 return make_scoped_ptr<SurfaceOzoneCanvas>(new FileSurface(window->path())); | 98 return make_scoped_ptr<SurfaceOzoneCanvas>(new FileSurface(window->path())); |
| 106 } | 99 } |
| 107 | 100 |
| 108 bool TestWindowManager::LoadEGLGLES2Bindings( | 101 bool TestWindowManager::LoadEGLGLES2Bindings( |
| 109 AddGLLibraryCallback add_gl_library, | 102 AddGLLibraryCallback add_gl_library, |
| 110 SetGLGetProcAddressProcCallback set_gl_get_proc_address) { | 103 SetGLGetProcAddressProcCallback set_gl_get_proc_address) { |
| 111 return false; | 104 return false; |
| 112 } | 105 } |
| 113 | 106 |
| 114 } // namespace ui | 107 } // namespace ui |
| OLD | NEW |