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

Unified Diff: ui/wayland/wayland_screen.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 side-by-side diff with in-line comments
Download patch
Index: ui/wayland/wayland_screen.h
diff --git a/ui/wayland/wayland_screen.h b/ui/wayland/wayland_screen.h
new file mode 100644
index 0000000000000000000000000000000000000000..90f406076f30c24be0c8c6cdbfcd7c3d8e4fa181
--- /dev/null
+++ b/ui/wayland/wayland_screen.h
@@ -0,0 +1,55 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef WAYLAND_SCREEN_H_
+#define WAYLAND_SCREEN_H_
+
+#include <list>
+#include <stdint.h>
+
+#include "wayland_geometry_utils.h"
+
+struct wl_output;
+
+class WaylandDisplay;
+
+class WaylandScreen {
+ public:
+ WaylandScreen(WaylandDisplay* display, uint32_t id);
+ ~WaylandScreen();
+
+ Rectangle GetAllocation() const;
+
+ private:
+ struct Mode {
+ int32_t width, height, refresh, flags;
+ };
+
+ struct wl_output* output_;
+ WaylandDisplay* display_;
+ Point position_;
+
+ typedef std::list<Mode> Modes;
+ Modes modes_;
+
+ static const struct wl_output_listener output_listener;
+
+ static void OutputHandleGeometry(void* data,
+ struct wl_output* output,
+ int32_t x,
+ int32_t y,
+ int32_t physical_width,
+ int32_t physical_height,
+ int32_t subpixel,
+ const char* make,
+ const char* model);
+ static void OutputHandleMode(void* data,
+ struct wl_output* wl_output,
+ uint32_t flags,
+ int32_t width,
+ int32_t height,
+ int32_t refresh);
+};
+
+#endif

Powered by Google App Engine
This is Rietveld 408576698