src/video/wayland/SDL_waylandwindow.c
changeset 8712 e33b5f7df761
parent 8149 681eb46b8ac4
child 8766 e5f584f77609
equal deleted inserted replaced
8711:46f85bfe9303 8712:e33b5f7df761
   162     if (c->surface_extension) {
   162     if (c->surface_extension) {
   163         data->extended_surface = qt_surface_extension_get_extended_surface(
   163         data->extended_surface = qt_surface_extension_get_extended_surface(
   164                 c->surface_extension, data->surface);
   164                 c->surface_extension, data->surface);
   165     }
   165     }
   166 #endif /* SDL_VIDEO_DRIVER_WAYLAND_QT_TOUCH */
   166 #endif /* SDL_VIDEO_DRIVER_WAYLAND_QT_TOUCH */
       
   167 
       
   168     /**
       
   169      * If the user specified 0x0 as the size (turned to 1x1 by SDL_CreateWindow
       
   170      * in SDL_video.c), we want to make the window fill the whole screen
       
   171      **/
       
   172     if (window->w == 1) {
       
   173         window->w = c->screen_allocation.width;
       
   174     }
       
   175     if (window->h == 1) {
       
   176         window->h = c->screen_allocation.height;
       
   177     }
       
   178 
   167     data->egl_window = WAYLAND_wl_egl_window_create(data->surface,
   179     data->egl_window = WAYLAND_wl_egl_window_create(data->surface,
   168                                             window->w, window->h);
   180                                             window->w, window->h);
   169 
   181 
   170     /* Create the GLES window surface */
   182     /* Create the GLES window surface */
   171     data->egl_surface = SDL_EGL_CreateSurface(_this, (NativeWindowType) data->egl_window);
   183     data->egl_surface = SDL_EGL_CreateSurface(_this, (NativeWindowType) data->egl_window);