Mercurial > mm7
comparison Engine/Graphics/Render.cpp @ 2560:44d9df75dc13
Слияние
author | Ritor1 |
---|---|
date | Thu, 14 May 2015 19:16:21 +0600 |
parents | 6ab1273bc507 67d837007a4c |
children | 98057834c9a0 |
comparison
equal
deleted
inserted
replaced
2559:6ab1273bc507 | 2560:44d9df75dc13 |
---|---|
1248 this->pHost->SetCooperativeLevel(this->hWindow, DDSCL_NORMAL); | 1248 this->pHost->SetCooperativeLevel(this->hWindow, DDSCL_NORMAL); |
1249 this->pHost->FlipToGDISurface(); | 1249 this->pHost->FlipToGDISurface(); |
1250 } | 1250 } |
1251 } | 1251 } |
1252 | 1252 |
1253 for (int i = 0; i < 4; i++) | 1253 for (int i = 0; i < 4; i++) |
1254 { | 1254 { |
1255 delete[] this->pAvailableDevices[i].pDriverName; | 1255 if (this->pAvailableDevices[i].pDriverName) |
1256 this->pAvailableDevices[i].pDriverName = nullptr; | 1256 { |
1257 | 1257 delete[] this->pAvailableDevices[i].pDriverName; |
1258 delete[] this->pAvailableDevices[i].pDeviceDesc; | 1258 this->pAvailableDevices[i].pDriverName = nullptr; |
1259 this->pAvailableDevices[i].pDeviceDesc = nullptr; | 1259 } |
1260 | 1260 |
1261 delete[] this->pAvailableDevices[i].pDDraw4DevDesc; | 1261 if (this->pAvailableDevices[i].pDeviceDesc) |
1262 this->pAvailableDevices[i].pDDraw4DevDesc = nullptr; | 1262 { |
1263 | 1263 delete[] this->pAvailableDevices[i].pDeviceDesc; |
1264 delete this->pAvailableDevices[i].pDirectDrawGUID; | 1264 this->pAvailableDevices[i].pDeviceDesc = nullptr; |
1265 this->pAvailableDevices[i].pDirectDrawGUID = nullptr; | 1265 } |
1266 | 1266 |
1267 delete[] this->pAvailableDevices[i].pName; | 1267 if (this->pAvailableDevices[i].pDDraw4DevDesc) |
1268 this->pAvailableDevices[i].pName = nullptr; | 1268 { |
1269 | 1269 delete[] this->pAvailableDevices[i].pDDraw4DevDesc; |
1270 delete[] this->pAvailableDevices[i].pDescription; | 1270 this->pAvailableDevices[i].pDDraw4DevDesc = nullptr; |
1271 this->pAvailableDevices[i].pDescription = nullptr; | 1271 } |
1272 | 1272 |
1273 delete this->pAvailableDevices[i].pGUID; | 1273 if (this->pAvailableDevices[i].pDirectDrawGUID) |
1274 this->pAvailableDevices[i].pGUID = nullptr; | 1274 { |
1275 delete this->pAvailableDevices[i].pDirectDrawGUID; | |
1276 this->pAvailableDevices[i].pDirectDrawGUID = nullptr; | |
1277 } | |
1278 | |
1279 if (this->pAvailableDevices[i].pName) | |
1280 { | |
1281 delete[] this->pAvailableDevices[i].pName; | |
1282 this->pAvailableDevices[i].pName = nullptr; | |
1283 } | |
1284 | |
1285 if (this->pAvailableDevices[i].pDescription) | |
1286 { | |
1287 delete[] this->pAvailableDevices[i].pDescription; | |
1288 this->pAvailableDevices[i].pDescription = nullptr; | |
1289 } | |
1290 | |
1291 if (this->pAvailableDevices[i].pGUID) | |
1292 { | |
1293 delete this->pAvailableDevices[i].pGUID; | |
1294 this->pAvailableDevices[i].pGUID = nullptr; | |
1295 } | |
1275 } | 1296 } |
1276 | 1297 |
1277 delete[] this->pAvailableDevices; | 1298 delete[] this->pAvailableDevices; |
1278 this->pAvailableDevices = NULL; | 1299 this->pAvailableDevices = NULL; |
1279 | 1300 |