Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2011 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 AURA_DESKTOP_HOST_H_ | |
| 6 #define AURA_DESKTOP_HOST_H_ | |
| 7 #pragma once | |
| 8 | |
| 9 #include "ui/gfx/native_widget_types.h" | |
| 10 | |
| 11 namespace gfx { | |
| 12 class Rect; | |
| 13 class Size; | |
| 14 } | |
| 15 | |
| 16 namespace aura { | |
| 17 | |
| 18 class Desktop; | |
| 19 | |
| 20 // DesktopHost bridges between a native window and the embedded Desktop. It | |
| 21 // provides the accelerated widget and maps events from the native os to aura. | |
| 22 class DesktopHost { | |
| 23 public: | |
| 24 virtual ~DesktopHost() {} | |
| 25 | |
| 26 // Creates a new DesktopHost. The caller owners the returned value. | |
|
Daniel Erat
2011/07/28 23:00:37
s/owners/owns/
| |
| 27 static DesktopHost* Create(const gfx::Rect& bounds); | |
| 28 | |
| 29 // Sets the Desktop this DesktopHost is hosting. DesktopHost does not own the | |
| 30 // Desktop. | |
| 31 virtual void SetDesktop(Desktop* desktop) = 0; | |
| 32 | |
| 33 // Returns the accelerated widget. | |
| 34 virtual gfx::AcceleratedWidget GetAcceleratedWidget() = 0; | |
| 35 | |
| 36 // Shows the DesktopHost. | |
| 37 virtual void Show() = 0; | |
| 38 | |
| 39 // Returns the size of the DesktopHost. | |
| 40 virtual gfx::Size GetSize() = 0; | |
| 41 }; | |
| 42 | |
| 43 } // namespace aura | |
| 44 | |
| 45 #endif // AURA_DESKTOP_HOST_H_ | |
| OLD | NEW |