egl: Add Haiku code and support
[mesa.git] / src / gallium / targets / graw-gdi / graw_gdi.c
index bd6242b0779c5da7774549c0397b342ccac075c0..99d8641d6b1162a3b8a9eea502836074d76c2170 100644 (file)
@@ -29,7 +29,7 @@
 #include "gdi/gdi_sw_winsys.h"
 #include "pipe/p_screen.h"
 #include "state_tracker/graw.h"
-#include "target-helpers/wrap_screen.h"
+#include "target-helpers/inline_debug_helper.h"
 #include "target-helpers/inline_sw_helper.h"
 #include <windows.h>
 
@@ -66,7 +66,7 @@ graw_create_window_and_screen(int x,
 {
    struct sw_winsys *winsys = NULL;
    struct pipe_screen *screen = NULL;
-   WNDCLASSEX wc = {sizeof(wc)};
+   WNDCLASSEX wc;
    UINT style = WS_VISIBLE | WS_TILEDWINDOW;
    RECT rect;
    HWND hWnd = NULL;
@@ -83,6 +83,8 @@ graw_create_window_and_screen(int x,
    if (screen == NULL)
       goto fail;
 
+   memset(&wc, 0, sizeof wc);
+   wc.cbSize = sizeof wc;
    wc.style = CS_OWNDC | CS_HREDRAW | CS_VREDRAW;
    wc.lpfnWndProc = window_proc;
    wc.lpszClassName = "graw-gdi";
@@ -116,7 +118,7 @@ graw_create_window_and_screen(int x,
 
    *handle = (void *)hDC;
 
-   return gallium_wrap_screen(screen);
+   return debug_screen_wrap(screen);
 
 fail:
    if (hWnd)