[gtk+/wip/mir2] mir: stop using deprecated surface api
- From: William Hua <williamhua src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/mir2] mir: stop using deprecated surface api
- Date: Tue, 20 Jan 2015 16:34:14 +0000 (UTC)
commit 8a3c558f64846c2bde864c475b4dcbc9cefbc71d
Author: William Hua <william attente ca>
Date: Mon Jan 19 12:08:43 2015 -0500
mir: stop using deprecated surface api
gdk/mir/gdkmirwindowimpl.c | 21 +++++++++++----------
1 files changed, 11 insertions(+), 10 deletions(-)
---
diff --git a/gdk/mir/gdkmirwindowimpl.c b/gdk/mir/gdkmirwindowimpl.c
index 37f96dc..4e0503b 100644
--- a/gdk/mir/gdkmirwindowimpl.c
+++ b/gdk/mir/gdkmirwindowimpl.c
@@ -183,19 +183,20 @@ create_mir_surface (GdkDisplay *display,
gint height,
MirBufferUsage buffer_usage)
{
- MirSurfaceParameters parameters;
+ MirSurfaceSpec *spec;
MirConnection *connection;
-
- parameters.name = g_get_prgname ();
- parameters.width = width;
- parameters.height = height;
- parameters.pixel_format = _gdk_mir_display_get_pixel_format (display, buffer_usage);
- parameters.buffer_usage = buffer_usage;
- parameters.output_id = mir_display_output_id_invalid;
+ MirPixelFormat format;
+ MirSurface *surface;
connection = gdk_mir_display_get_mir_connection (display);
-
- return mir_connection_create_surface_sync (connection, ¶meters);
+ format = _gdk_mir_display_get_pixel_format (display, buffer_usage);
+ spec = mir_connection_create_spec_for_normal_surface (connection, width, height, format);
+ mir_surface_spec_set_name (spec, g_get_prgname ());
+ mir_surface_spec_set_buffer_usage (spec, buffer_usage);
+ surface = mir_surface_create_sync (spec);
+ mir_surface_spec_release (spec);
+
+ return surface;
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]