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

Side by Side Diff: ui/wayland/wayland_window.h

Issue 7457023: Adding a Wayland basic toolkit (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 5 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
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 WAYLAND_WINDOW_H_
6 #define WAYLAND_WINDOW_H_
7
8 #include <stdint.h>
9
10 #include "wayland_geometry_utils.h"
11
12 class WaylandDisplay;
13 class WaylandWidget;
14 struct wl_surface;
15
16 /*
17 WaylandWindow wraps a wl_surface and some basic operations for the surface.
18 WaylandWindow also keeps track of the WaylandWidget that will process all
19 events related to the window.
20 */
21 class WaylandWindow {
22 public:
23 // Creates a toplevel window
24 WaylandWindow(WaylandWidget* widget, WaylandDisplay* display);
25 // Creates a transient window
26 WaylandWindow(WaylandWidget* widget, WaylandDisplay* display,
27 WaylandWindow* parent, int32_t x, int32_t y);
28 virtual ~WaylandWindow();
29
30 void SetVisible(bool visible);
31 bool IsVisible() const;
32
33 void SetFullscreen(bool fullscreen);
34 bool IsFullscreen() const;
35
36 WaylandWindow* GetParentWindow() const;
37
38 WaylandWidget* GetWidget() const;
39 struct wl_surface* GetSurface() const;
40
41 void Configure(uint32_t time, uint32_t edges, int32_t x, int32_t y,
42 int32_t width, int32_t height);
43 private:
44 WaylandWidget* widget_;
45 WaylandDisplay* display_;
46
47 struct wl_surface* surface_;
48
49 bool fullscreen_;
50
51 WaylandWindow* parent_window_;
52 // Position relative to parent window. This is only used by
53 // a transient window.
54 Point relative_position_;
55 };
56
57 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698