[mutter/wayland] wayland: Move "public" Wayland API to another header file
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wayland] wayland: Move "public" Wayland API to another header file
- Date: Fri, 28 Feb 2014 17:22:47 +0000 (UTC)
commit 770b58b3675dd3fb863d25211be4923c819877be
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Fri Feb 28 10:24:06 2014 -0500
wayland: Move "public" Wayland API to another header file
src/Makefile.am | 1 +
src/compositor/meta-plugin.c | 1 +
src/compositor/meta-surface-actor-wayland.c | 1 +
src/compositor/meta-surface-actor-wayland.h | 2 +-
src/compositor/meta-surface-actor.c | 1 -
src/compositor/meta-window-actor-private.h | 3 --
src/compositor/meta-window-actor.c | 2 +-
src/core/keybindings.c | 2 +-
src/core/main.c | 2 +-
src/core/monitor.c | 1 -
src/core/screen.c | 2 +-
src/wayland/meta-wayland-keyboard.h | 1 +
src/wayland/meta-wayland-private.h | 25 +------------
src/wayland/meta-wayland.h | 51 +++++++++++++++++++++++++++
14 files changed, 61 insertions(+), 34 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 2221a5d..8df85fb 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -189,6 +189,7 @@ libmutter_wayland_la_SOURCES = \
ui/theme-private.h \
ui/ui.c \
wayland/meta-wayland.c \
+ wayland/meta-wayland.h \
wayland/meta-wayland-private.h \
wayland/meta-xwayland-private.h \
wayland/meta-xwayland.c \
diff --git a/src/compositor/meta-plugin.c b/src/compositor/meta-plugin.c
index 8cdc0ed..444d81e 100644
--- a/src/compositor/meta-plugin.c
+++ b/src/compositor/meta-plugin.c
@@ -30,6 +30,7 @@
#include "meta-plugin-manager.h"
#include <meta/screen.h>
#include <meta/display.h>
+#include <meta/util.h>
#include <string.h>
#include <X11/Xlib.h>
diff --git a/src/compositor/meta-surface-actor-wayland.c b/src/compositor/meta-surface-actor-wayland.c
index c838193..56dd8bd 100644
--- a/src/compositor/meta-surface-actor-wayland.c
+++ b/src/compositor/meta-surface-actor-wayland.c
@@ -28,6 +28,7 @@
#include <cogl/cogl-wayland-server.h>
#include "meta-shaped-texture-private.h"
+#include "meta-wayland-private.h"
struct _MetaSurfaceActorWaylandPrivate
{
diff --git a/src/compositor/meta-surface-actor-wayland.h b/src/compositor/meta-surface-actor-wayland.h
index 89c6b30..fbca3ff 100644
--- a/src/compositor/meta-surface-actor-wayland.h
+++ b/src/compositor/meta-surface-actor-wayland.h
@@ -29,7 +29,7 @@
#include "meta-surface-actor.h"
-#include "meta-wayland-private.h"
+#include "meta-wayland.h"
G_BEGIN_DECLS
diff --git a/src/compositor/meta-surface-actor.c b/src/compositor/meta-surface-actor.c
index 1d9a7ad..7b4fc29 100644
--- a/src/compositor/meta-surface-actor.c
+++ b/src/compositor/meta-surface-actor.c
@@ -15,7 +15,6 @@
#include <clutter/clutter.h>
#include <meta/meta-shaped-texture.h>
-#include "meta-wayland-private.h"
#include "meta-cullable.h"
#include "meta-shaped-texture-private.h"
diff --git a/src/compositor/meta-window-actor-private.h b/src/compositor/meta-window-actor-private.h
index 021ddc6..2d27850 100644
--- a/src/compositor/meta-window-actor-private.h
+++ b/src/compositor/meta-window-actor-private.h
@@ -5,9 +5,6 @@
#include <config.h>
-#include <wayland-server.h>
-#include <meta-wayland-private.h>
-
#include <X11/extensions/Xdamage.h>
#include <meta/compositor-mutter.h>
#include "meta-surface-actor.h"
diff --git a/src/compositor/meta-window-actor.c b/src/compositor/meta-window-actor.c
index 89c6b4e..cf62d99 100644
--- a/src/compositor/meta-window-actor.c
+++ b/src/compositor/meta-window-actor.c
@@ -28,9 +28,9 @@
#include "meta-window-actor-private.h"
#include "meta-texture-rectangle.h"
#include "region-utils.h"
-#include "meta-wayland-private.h"
#include "monitor-private.h"
#include "meta-cullable.h"
+#include "meta-wayland-private.h"
#include "meta-surface-actor.h"
#include "meta-surface-actor-x11.h"
diff --git a/src/core/keybindings.c b/src/core/keybindings.c
index 6004829..adfa2c6 100644
--- a/src/core/keybindings.c
+++ b/src/core/keybindings.c
@@ -41,7 +41,7 @@
#include "screen-private.h"
#include <meta/prefs.h>
#include "util-private.h"
-#include "meta-wayland-private.h"
+#include "meta-wayland.h"
#include <X11/keysym.h>
#include <string.h>
diff --git a/src/core/main.c b/src/core/main.c
index 84da691..5a8f91b 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -53,7 +53,7 @@
#include "session.h"
#include <meta/prefs.h>
#include <meta/compositor.h>
-#include "meta-wayland-private.h"
+#include "meta-wayland.h"
#include <glib-object.h>
#include <glib-unix.h>
diff --git a/src/core/monitor.c b/src/core/monitor.c
index 9c22992..2b2c1f7 100644
--- a/src/core/monitor.c
+++ b/src/core/monitor.c
@@ -34,7 +34,6 @@
#include "util-private.h"
#include <meta/errors.h>
#include "monitor-private.h"
-#include "meta-wayland-private.h"
#include "meta-dbus-xrandr.h"
diff --git a/src/core/screen.c b/src/core/screen.c
index d99814b..5bcc6bf 100644
--- a/src/core/screen.c
+++ b/src/core/screen.c
@@ -43,7 +43,7 @@
#include <meta/compositor.h>
#include "mutter-enum-types.h"
#include "core.h"
-#include "meta-wayland-private.h"
+#include "meta-wayland.h"
#include "meta-cursor-tracker-private.h"
#include <X11/extensions/Xinerama.h>
diff --git a/src/wayland/meta-wayland-keyboard.h b/src/wayland/meta-wayland-keyboard.h
index b51d3c0..8d2cb06 100644
--- a/src/wayland/meta-wayland-keyboard.h
+++ b/src/wayland/meta-wayland-keyboard.h
@@ -47,6 +47,7 @@
#include <clutter/clutter.h>
#include <wayland-server.h>
+#include <xkbcommon/xkbcommon.h>
struct _MetaWaylandKeyboardGrabInterface
{
diff --git a/src/wayland/meta-wayland-private.h b/src/wayland/meta-wayland-private.h
index 69de1b8..a2a2b90 100644
--- a/src/wayland/meta-wayland-private.h
+++ b/src/wayland/meta-wayland-private.h
@@ -21,7 +21,6 @@
#define META_WAYLAND_PRIVATE_H
#include <wayland-server.h>
-#include <xkbcommon/xkbcommon.h>
#include <clutter/clutter.h>
#include <glib.h>
@@ -31,7 +30,7 @@
#include "meta-weston-launch.h"
#include <meta/meta-cursor-tracker.h>
-#include "meta-wayland-types.h"
+#include "meta-wayland.h"
#include "meta-wayland-versions.h"
#include "meta-wayland-surface.h"
#include "meta-wayland-seat.h"
@@ -91,30 +90,8 @@ struct _MetaWaylandCompositor
MetaWaylandSeat *seat;
};
-void meta_wayland_init (void);
-void meta_wayland_finalize (void);
-
-/* We maintain a singleton MetaWaylandCompositor which can be got at via this
- * API after meta_wayland_init() has been called. */
-MetaWaylandCompositor *meta_wayland_compositor_get_default (void);
-
-void meta_wayland_compositor_repick (MetaWaylandCompositor *compositor);
-
-void meta_wayland_compositor_set_input_focus (MetaWaylandCompositor *compositor,
- MetaWindow *window);
-gboolean meta_wayland_compositor_handle_event (MetaWaylandCompositor *compositor,
- const ClutterEvent *event);
-
MetaWaylandBuffer * meta_wayland_buffer_from_resource (struct wl_resource *resource);
void meta_wayland_buffer_ref (MetaWaylandBuffer *buffer);
void meta_wayland_buffer_unref (MetaWaylandBuffer *buffer);
-void meta_wayland_compositor_update (MetaWaylandCompositor *compositor,
- const ClutterEvent *event);
-void meta_wayland_compositor_paint_finished (MetaWaylandCompositor *compositor);
-
-gboolean meta_wayland_compositor_activate_vt (MetaWaylandCompositor *compositor,
- int vt,
- GError **error);
-
#endif /* META_WAYLAND_PRIVATE_H */
diff --git a/src/wayland/meta-wayland.h b/src/wayland/meta-wayland.h
new file mode 100644
index 0000000..481695a
--- /dev/null
+++ b/src/wayland/meta-wayland.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2014 Red Hat
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+ * 02111-1307, USA.
+ *
+ * Written by:
+ * Jasper St. Pierre <jstpierre mecheye net>
+ */
+
+#ifndef META_WAYLAND_H
+#define META_WAYLAND_H
+
+#include "meta-wayland-types.h"
+
+void meta_wayland_init (void);
+void meta_wayland_finalize (void);
+
+/* We maintain a singleton MetaWaylandCompositor which can be got at via this
+ * API after meta_wayland_init() has been called. */
+MetaWaylandCompositor *meta_wayland_compositor_get_default (void);
+
+void meta_wayland_compositor_repick (MetaWaylandCompositor *compositor);
+
+void meta_wayland_compositor_set_input_focus (MetaWaylandCompositor *compositor,
+ MetaWindow *window);
+gboolean meta_wayland_compositor_handle_event (MetaWaylandCompositor *compositor,
+ const ClutterEvent *event);
+
+void meta_wayland_compositor_update (MetaWaylandCompositor *compositor,
+ const ClutterEvent *event);
+void meta_wayland_compositor_paint_finished (MetaWaylandCompositor *compositor);
+
+gboolean meta_wayland_compositor_activate_vt (MetaWaylandCompositor *compositor,
+ int vt,
+ GError **error);
+
+#endif
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]