Skip to content

Commit 99c3826

Browse files
committed
Fixed bug with unsaved ui style
1 parent d354433 commit 99c3826

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/xrGame/GamePersistent.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,6 @@ void CGamePersistent::OnAppEnd()
224224
clean_game_globals();
225225

226226
GMLib.Unload();
227-
CleanupUIStyleToken();
228227
}
229228

230229
void CGamePersistent::Start(LPCSTR op) { inherited::Start(op); }

src/xrGame/xrGame.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
#include "xrEngine/profiler.h"
1414

1515
extern void FillUIStyleToken();
16+
extern void CleanupUIStyleToken();
1617

1718
extern "C" {
1819
DLL_API IFactoryObject* __cdecl xrFactory_Create(CLASS_ID clsid)
@@ -51,7 +52,10 @@ BOOL APIENTRY DllMain(HANDLE hModule, u32 ul_reason_for_call, LPVOID lpReserved)
5152
break;
5253
}
5354

54-
case DLL_PROCESS_DETACH: { break;
55+
case DLL_PROCESS_DETACH:
56+
{
57+
CleanupUIStyleToken();
58+
break;
5559
}
5660
}
5761
return (TRUE);

0 commit comments

Comments
 (0)