1
0
mirror of https://github.com/blupi-games/planetblupi synced 2024-12-30 10:15:36 +01:00

Remove ddraw cursor

This commit is contained in:
Mathieu Schroeter 2017-02-05 10:04:05 +01:00
parent 1e3b92218a
commit cbd1348760
2 changed files with 9 additions and 6 deletions

View File

@ -37,7 +37,9 @@ CPixmap::CPixmap()
m_lpDD = NULL;
m_lpDDSPrimary = NULL;
m_lpDDSBack = NULL;
m_lpDDSMouse = NULL;
for (i = 0; i < MAXCURSORS; i++)
m_lpSDLCursors[i] = nullptr;
for ( i=0 ; i<MAXIMAGE ; i++ )
{
@ -71,10 +73,13 @@ CPixmap::~CPixmap()
m_lpDDSBack = NULL;
}
if ( m_lpDDSMouse != NULL )
for (i = 0; i < MAXIMAGE; i++)
{
m_lpDDSMouse->Release();
m_lpDDSMouse = NULL;
if (m_lpSDLCursors[i])
{
SDL_FreeCursor (m_lpSDLCursors[i]);
m_lpSDLCursors[i] = nullptr;
}
}
for ( i=0 ; i<MAXIMAGE ; i++ )

View File

@ -71,11 +71,9 @@ protected:
SDL_Surface * m_lpSDLPrimary;
LPDIRECTDRAWSURFACE m_lpDDSBack; // DirectDraw back surface
SDL_Surface * m_lpSDLBack;
LPDIRECTDRAWSURFACE m_lpDDSMouse; // DirectDraw back surface
SDL_Cursor * m_lpCurrentCursor;
SDL_Cursor * m_lpSDLCursors[MAXCURSORS];
SDL_Surface * m_lpSDLBlupi;
SDL_Surface * m_lpSDLSurface[MAXIMAGE];
SDL_Texture * m_lpSDLTexture[MAXIMAGE];
COLORREF m_colorSurface[2*MAXIMAGE];