here's the fix for the title menu multiple loading of the
msimg32.dll library that might cause this issue
(or this will at least reduce memory usage and function call)
note that i haven't compiled the code yet but it should work
(since it's based on my improved MiniMule code & the api used in Title Menu)
Quote
typedef UINT (WINAPI* LPFNGRADIENTFILL)(HDC, CONST PTRIVERTEX, DWORD, CONST PVOID, DWORD, DWORD); // Avi3k: fix & improve code
...
protected:
...
// Avi3k: fix & improve code
//typedef UINT (WINAPI* LPFNGRADIENTFILL)(HDC, CONST PTRIVERTEX, DWORD, CONST PVOID, DWORD, DWORD);
static LPFNGRADIENTFILL m_pfnGradientFill;
//HINSTANCE m_hLibMsimg32;
// end Avi3k: fix & improve code
...
Quote
bool CTitleMenu::m_bInitializedAPI = false;
LPFNGRADIENTFILL CTitleMenu::m_pfnGradientFill = NULL; // Avi3k: fix & improve code
...
CTitleMenu::CTitleMenu() {
...
m_clText = ::GetSysColor(COLOR_CAPTIONTEXT);
// Avi3k: fix & improve code
if (!g_bLowColorDesktop && !m_pfnGradientFill)
{
m_pfnGradientFill = (LPFNGRADIENTFILL)GetProcAddress(GetModuleHandle(_T("msimg32")), "GradientFill");
}
// end Avi3k: fix & improve code
m_bDrawEdge = false;
...
}
...
CTitleMenu::~CTitleMenu()
{
// Avi3k: fix + improve code
//if (m_hLibMsimg32)
// FreeLibrary(m_hLibMsimg32);
// end Avi3k: fix + improve code
}
...
blue = add, red = comment out or remove, green = modify
if anyone can test and verify, please do so... thanx...
Avi3k