Remove Win32 wide char aliases from DLC UI flows

This commit is contained in:
notmatthewbeshay 2026-03-11 00:12:24 +11:00
parent c17c613692
commit dc342c092d
2 changed files with 4 additions and 5 deletions

View file

@ -58,7 +58,7 @@ void IUIScene_StartGame::HandleDLCMountingComplete()
char *pchName=app.GetDLCInfoTextures(i);
pDLCInfo=app.GetDLCInfo(pchName);
#elif defined _XBOX_ONE
pDLCInfo=app.GetDLCInfoForFullOfferID((WCHAR *)app.GetDLCInfoTexturesFullOffer(i).c_str());
pDLCInfo=app.GetDLCInfoForFullOfferID(const_cast<wchar_t *>(app.GetDLCInfoTexturesFullOffer(i).c_str()));
#else
ULONGLONG ull=app.GetDLCInfoTexturesFullOffer(i);
pDLCInfo=app.GetDLCInfoForFullOfferID(ull);
@ -362,7 +362,7 @@ int IUIScene_StartGame::TexturePackDialogReturned(void *pParam,int iPad,C4JStora
app.GetDLCFullOfferIDForPackID(pClass->m_MoreOptionsParams.dwTexturePack,ProductId);
StorageManager.InstallOffer(1,(WCHAR *)ProductId.c_str(),NULL,NULL);
StorageManager.InstallOffer(1, const_cast<wchar_t *>(ProductId.c_str()), NULL, NULL);
// the license change coming in when the offer has been installed will cause this scene to refresh
}

View file

@ -738,8 +738,7 @@ void UIScene_DLCOffersMenu::GetDLCInfo( int iOfferC, bool bUpdateOnly )
if(wcsncmp(L"Minecraft ",wstrTemp.c_str(),10)==0)
{
app.DebugPrintf("Removing Minecraft from name\n");
WCHAR *pwchNewName=(WCHAR *)wstrTemp.c_str();
wstrTemp=&pwchNewName[10];
wstrTemp = wstrTemp.substr(10);
}
#ifdef _XBOX_ONE
@ -822,7 +821,7 @@ bool UIScene_DLCOffersMenu::UpdateDisplay(MARKETPLACE_CONTENTOFFER_INFO& xOffer)
if (dlc != NULL)
{
WCHAR *cString = dlc->wchBanner;
wchar_t *cString = dlc->wchBanner;
// is the file in the local DLC images?