first commit
This commit is contained in:
32
Minecraft.Client/Common/DLC/DLCUIDataFile.cpp
Normal file
32
Minecraft.Client/Common/DLC/DLCUIDataFile.cpp
Normal file
@@ -0,0 +1,32 @@
|
||||
#include "stdafx.h"
|
||||
#include "DLCManager.h"
|
||||
#include "DLCUIDataFile.h"
|
||||
|
||||
DLCUIDataFile::DLCUIDataFile(const wstring &path) : DLCFile(DLCManager::e_DLCType_UIData,path)
|
||||
{
|
||||
m_pbData = NULL;
|
||||
m_dwBytes = 0;
|
||||
m_canDeleteData = false;
|
||||
}
|
||||
|
||||
DLCUIDataFile::~DLCUIDataFile()
|
||||
{
|
||||
if(m_canDeleteData && m_pbData != NULL)
|
||||
{
|
||||
app.DebugPrintf("Deleting DLCUIDataFile data\n");
|
||||
delete [] m_pbData;
|
||||
}
|
||||
}
|
||||
|
||||
void DLCUIDataFile::addData(PBYTE pbData, DWORD dwBytes,bool canDeleteData)
|
||||
{
|
||||
m_pbData = pbData;
|
||||
m_dwBytes = dwBytes;
|
||||
m_canDeleteData = canDeleteData;
|
||||
}
|
||||
|
||||
PBYTE DLCUIDataFile::getData(DWORD &dwBytes)
|
||||
{
|
||||
dwBytes = m_dwBytes;
|
||||
return m_pbData;
|
||||
}
|
||||
Reference in New Issue
Block a user