diff UI/UIMainMenu.cpp @ 1583:75fafd8ced59

Allocator (CMemory) bye-bye
author Nomad
date Tue, 10 Sep 2013 21:07:07 +0200
parents 19f1735fca80
children 8094f1706b1f d17247968bd6
line wrap: on
line diff
--- a/UI/UIMainMenu.cpp	Tue Sep 10 18:43:52 2013 +0200
+++ b/UI/UIMainMenu.cpp	Tue Sep 10 21:07:07 2013 +0200
@@ -10,7 +10,6 @@
 #include "..\AudioPlayer.h"
 #include "..\Render.h"
 #include "..\LOD.h"
-#include "..\Allocator.h"
 #include "..\PaletteManager.h"
 #include "..\IconFrameTable.h"
 #include "..\texts.h"
@@ -290,13 +289,12 @@
         pHeight = pFont2->GetStringHeight2(pFont, v1, &a2, 0, 1);
         pTexture2.uHeight = pHeight + 2 * a2.uFrameHeight;
         pTexture2.uNumPixels = (signed __int16)pTexture2.uWidth * (signed __int16)pTexture2.uHeight;
-        v7 = pAllocator->AllocNamedChunk(pTexture2.pPixels, 2 * pTexture2.uNumPixels, "scrollermap");
+        v7 = malloc(2 * pTexture2.uNumPixels);//, "scrollermap");
         pNumPixels = pTexture2.uNumPixels;
         pTexture2.pPixels = (unsigned __int16 *)v7;
         teal = TargetColor(0, 0xFFu, 0xFFu);
         fill_pixels_fast(teal, pTexture2.pPixels, pNumPixels);
-        pTexture2.field_20 = 0;
-        pTexture2.field_22 = 0;
+        pTexture2._allocation_flags = 0;
         pColor1 = TargetColor(0x70u, 0x8Fu, 0xFEu);
         pColor2 = TargetColor(0xECu, 0xE6u, 0x9Cu);
         pString = (char *)operator new(2 * pSize);
@@ -340,9 +338,9 @@
             }
             while ( GetCurrentMenuID() == MENU_CREDITSPROC );
             pAudioPlayer->_4AA258(1);
-            pAllocator->FreeChunk(ptr);
-            pAllocator->FreeChunk(pFontQuick);
-            pAllocator->FreeChunk(pFontCChar);
+            free(ptr);
+            free(pFontQuick);
+            free(pFontCChar);
             pWindow_MainMenu->Release();
             pIcons_LOD->RemoveTexturesPackFromTextureList();
             pTexture.Release();