src/video/wayland/SDL_waylandwindow.c
changeset 8104 2e4f1bd21196
parent 8082 5b83ad3f01ac
child 8116 f7c2f71251e5
--- a/src/video/wayland/SDL_waylandwindow.c	Wed Jan 08 14:53:08 2014 -0500
+++ b/src/video/wayland/SDL_waylandwindow.c	Thu Jan 09 13:56:21 2014 -0300
@@ -19,7 +19,7 @@
   3. This notice may not be removed or altered from any source distribution.
 */
 
-#include "SDL_config.h"
+#include "../../SDL_internal.h"
 
 #include "../SDL_sysvideo.h"
 #include "../../events/SDL_windowevents_c.h"
@@ -104,7 +104,7 @@
     else
         wl_shell_surface_set_toplevel(wind->shell_surface);
 
-    wayland_schedule_write(_this->driverdata);
+    WAYLAND_wl_display_flush( ((SDL_VideoData*)_this->driverdata)->display );
 }
 
 void
@@ -120,7 +120,7 @@
     else
         wl_shell_surface_set_toplevel(wind->shell_surface);
 
-    wayland_schedule_write(_this->driverdata);
+    WAYLAND_wl_display_flush( ((SDL_VideoData*)_this->driverdata)->display );
 }
 
 int Wayland_CreateWindow(_THIS, SDL_Window *window)
@@ -162,7 +162,7 @@
                 c->surface_extension, data->surface);
     }
 #endif /* SDL_VIDEO_DRIVER_WAYLAND_QT_TOUCH */
-    data->egl_window = wl_egl_window_create(data->surface,
+    data->egl_window = WAYLAND_wl_egl_window_create(data->surface,
                                             window->w, window->h);
 
     /* Create the GLES window surface */
@@ -192,7 +192,7 @@
     wl_surface_set_opaque_region(data->surface, region);
     wl_region_destroy(region);
 
-    wayland_schedule_write(c);
+    WAYLAND_wl_display_flush(c->display);
 
     return 0;
 }
@@ -203,9 +203,9 @@
     SDL_WindowData *wind = window->driverdata;
     struct wl_region *region;
 
-    wl_egl_window_resize(wind->egl_window, window->w, window->h, 0, 0);
+    WAYLAND_wl_egl_window_resize(wind->egl_window, window->w, window->h, 0, 0);
 
-    region = wl_compositor_create_region(data->compositor);
+    region =wl_compositor_create_region(data->compositor);
     wl_region_add(region, 0, 0, window->w, window->h);
     wl_surface_set_opaque_region(wind->surface, region);
     wl_region_destroy(region);
@@ -220,7 +220,7 @@
 
     if (data) {
         SDL_EGL_DestroySurface(_this, wind->egl_surface);
-        wl_egl_window_destroy(wind->egl_window);
+        WAYLAND_wl_egl_window_destroy(wind->egl_window);
 
         if (wind->shell_surface)
             wl_shell_surface_destroy(wind->shell_surface);
@@ -232,7 +232,7 @@
         wl_surface_destroy(wind->surface);
 
         SDL_free(wind);
-        wayland_schedule_write(data);
+        WAYLAND_wl_display_flush(data->display);
     }
 }