Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef COMPONENTS_EXO_DISPLAY_H_ | |
| 6 #define COMPONENTS_EXO_DISPLAY_H_ | |
| 7 | |
| 8 #include "base/basictypes.h" | |
| 9 #include "base/memory/scoped_ptr.h" | |
| 10 #include "base/memory/shared_memory_handle.h" | |
| 11 #include "components/exo/exo_export.h" | |
| 12 | |
| 13 namespace exo { | |
| 14 class SharedMemory; | |
| 15 class ShellSurface; | |
| 16 class Surface; | |
| 17 | |
| 18 // The core display class. This class provides functions for creating surfaces | |
| 19 // and is in charge of combining the contents of multiple surfaces into one | |
| 20 // displayable output. | |
| 21 class EXO_EXPORT Display { | |
| 22 public: | |
| 23 Display(); | |
| 24 ~Display(); | |
| 25 | |
| 26 // Creates a new surface. | |
| 27 scoped_ptr<Surface> CreateSurface(); | |
| 28 | |
| 29 // Creates a shared memory segment from |handle| of |size| with the | |
| 30 // given |id|. This function takes ownership of |handle|. | |
| 31 scoped_ptr<SharedMemory> CreateSharedMemory( | |
| 32 const base::SharedMemoryHandle& handle, | |
| 33 size_t size); | |
| 34 | |
| 35 // Creates a shell surface for an existing surface. | |
| 36 scoped_ptr<ShellSurface> GetShellSurface(Surface* surface); | |
|
piman
2015/11/17 02:43:53
nit: maybe CreateShellSurface
reveman
2015/11/17 18:04:04
Done.
| |
| 37 | |
| 38 private: | |
| 39 DISALLOW_COPY_AND_ASSIGN(Display); | |
| 40 }; | |
| 41 | |
| 42 } // namespace exo | |
| 43 | |
| 44 #endif // COMPONENTS_EXO_DISPLAY_H_ | |
| OLD | NEW |