comparison src/video/qnxgf/SDL_qnxgf.c @ 3685:64ce267332c6

Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
author Sam Lantinga <slouken@libsdl.org>
date Thu, 21 Jan 2010 06:21:52 +0000
parents 4b594623401b
children f7b03b6838cb
comparison
equal deleted inserted replaced
3684:cc564f08884f 3685:64ce267332c6
976 976
977 int 977 int
978 qnxgf_createwindow(_THIS, SDL_Window * window) 978 qnxgf_createwindow(_THIS, SDL_Window * window)
979 { 979 {
980 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata; 980 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata;
981 SDL_VideoDisplay *display = SDL_GetDisplayFromWindow(window); 981 SDL_VideoDisplay *display = window->display;
982 SDL_DisplayData *didata = (SDL_DisplayData *) display->driverdata; 982 SDL_DisplayData *didata = (SDL_DisplayData *) display->driverdata;
983 SDL_WindowData *wdata; 983 SDL_WindowData *wdata;
984 int32_t status; 984 int32_t status;
985 985
986 /* QNX GF supports fullscreen window modes only */ 986 /* QNX GF supports fullscreen window modes only */
1079 1079
1080 /* Enable mouse event collecting */ 1080 /* Enable mouse event collecting */
1081 hiddi_enable_mouse(); 1081 hiddi_enable_mouse();
1082 1082
1083 /* By default last created window got a input focus */ 1083 /* By default last created window got a input focus */
1084 SDL_SetKeyboardFocus(0, window->id); 1084 SDL_SetKeyboardFocus(0, window);
1085 SDL_SetMouseFocus(0, window->id); 1085 SDL_SetMouseFocus(0, window);
1086 1086
1087 /* Window has been successfully created */ 1087 /* Window has been successfully created */
1088 return 0; 1088 return 0;
1089 } 1089 }
1090 1090
1153 void 1153 void
1154 qnxgf_destroywindow(_THIS, SDL_Window * window) 1154 qnxgf_destroywindow(_THIS, SDL_Window * window)
1155 { 1155 {
1156 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata; 1156 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata;
1157 SDL_DisplayData *didata = 1157 SDL_DisplayData *didata =
1158 (SDL_DisplayData *) SDL_GetDisplayFromWindow(window)->driverdata; 1158 (SDL_DisplayData *) window->display->driverdata;
1159 SDL_WindowData *wdata = (SDL_WindowData *) window->driverdata; 1159 SDL_WindowData *wdata = (SDL_WindowData *) window->driverdata;
1160 1160
1161 if (wdata != NULL) { 1161 if (wdata != NULL) {
1162 #if defined(SDL_VIDEO_OPENGL_ES) 1162 #if defined(SDL_VIDEO_OPENGL_ES)
1163 /* Destroy OpenGL ES surface if it was created */ 1163 /* Destroy OpenGL ES surface if it was created */
1307 { 1307 {
1308 #if defined(SDL_VIDEO_OPENGL_ES) 1308 #if defined(SDL_VIDEO_OPENGL_ES)
1309 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata; 1309 SDL_VideoData *gfdata = (SDL_VideoData *) _this->driverdata;
1310 SDL_WindowData *wdata = (SDL_WindowData *) window->driverdata; 1310 SDL_WindowData *wdata = (SDL_WindowData *) window->driverdata;
1311 SDL_DisplayData *didata = 1311 SDL_DisplayData *didata =
1312 (SDL_DisplayData *) SDL_GetDisplayFromWindow(window)->driverdata; 1312 (SDL_DisplayData *) window->display->driverdata;
1313 EGLBoolean status; 1313 EGLBoolean status;
1314 int32_t gfstatus; 1314 int32_t gfstatus;
1315 EGLint configs; 1315 EGLint configs;
1316 uint32_t surfaces; 1316 uint32_t surfaces;
1317 uint32_t attr_pos; 1317 uint32_t attr_pos;