equal
deleted
inserted
replaced
1255 prevHat:= 'NoHat'; |
1255 prevHat:= 'NoHat'; |
1256 tmpHatSurf:= nil; |
1256 tmpHatSurf:= nil; |
1257 end; |
1257 end; |
1258 |
1258 |
1259 procedure freeModule; |
1259 procedure freeModule; |
|
1260 var fi: THWFont; |
1260 begin |
1261 begin |
1261 StoreRelease(false); |
1262 StoreRelease(false); |
|
1263 // make sure fonts are cleaned up |
|
1264 for fi:= Low(THWFont) to High(THWFont) do |
|
1265 with Fontz[fi] do |
|
1266 begin |
|
1267 if Handle <> nil then |
|
1268 begin |
|
1269 TTF_CloseFont(Handle); |
|
1270 Handle:= nil; |
|
1271 end; |
|
1272 end; |
|
1273 |
1262 TTF_Quit(); |
1274 TTF_Quit(); |
1263 {$IFDEF SDL2} |
1275 {$IFDEF SDL2} |
1264 SDL_GL_DeleteContext(SDLGLcontext); |
1276 SDL_GL_DeleteContext(SDLGLcontext); |
1265 SDL_DestroyWindow(SDLwindow); |
1277 SDL_DestroyWindow(SDLwindow); |
1266 {$ENDIF} |
1278 {$ENDIF} |