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

Side by Side Diff: aura/desktop.h

Issue 7534002: Shell of implementation for embedded windows. At this point this is (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Incorporate review feedback Created 9 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « aura/demo/demo_main.cc ('k') | aura/desktop.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(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_H_
6 #define AURA_DESKTOP_H_
7 #pragma once
8
9 #include <vector>
10
11 #include "base/basictypes.h"
12 #include "base/memory/ref_counted.h"
13 #include "ui/gfx/native_widget_types.h"
14
15 namespace gfx {
16 class Size;
17 }
18
19 namespace ui {
20 class Compositor;
21 class Window;
22 }
23
24 namespace aura {
25
26 // Desktop is responsible for hosting a set of windows.
27 class Desktop {
28 public:
29 Desktop(gfx::AcceleratedWidget widget, const gfx::Size& size);
30 ~Desktop();
31
32 // Draws the necessary set of windows.
33 void Draw();
34
35 // Compositor we're drawing to.
36 ui::Compositor* compositor() { return compositor_.get(); }
37
38 private:
39 friend class Window;
40
41 typedef std::vector<Window*> Windows;
42
43 // Methods invoked by Window.
44 // TODO: move these into an interface that Window uses to talk to Desktop.
45 void AddWindow(Window* window);
46 void RemoveWindow(Window* window);
47
48 scoped_refptr<ui::Compositor> compositor_;
49
50 // The windows. Topmost window is last.
51 std::vector<Window*> windows_;
52
53 DISALLOW_COPY_AND_ASSIGN(Desktop);
54 };
55
56 } // namespace aura
57
58 #endif // AURA_DESKTOP_H_
OLDNEW
« no previous file with comments | « aura/demo/demo_main.cc ('k') | aura/desktop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698