Skip to content

Commit da90327

Browse files
committed
Closed UxTheme.dll library
1 parent 536c79b commit da90327

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

MUSHclient.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1177,6 +1177,9 @@ void CMUSHclientApp::RestoreColumnConfiguration (LPCTSTR strName,
11771177

11781178
} // end of RestoreColumnConfiguration
11791179

1180+
extern HMODULE HModUXT;
1181+
#define THEMEGLUE_FREE() if (HModUXT != NULL) { FreeLibrary(HModUXT); HModUXT = NULL; }
1182+
11801183
int CMUSHclientApp::ExitInstance()
11811184
{
11821185
if (!bWine)
@@ -1211,6 +1214,8 @@ int CMUSHclientApp::ExitInstance()
12111214
if (db)
12121215
sqlite3_close(db);
12131216

1217+
THEMEGLUE_FREE ();
1218+
12141219
// free the resources DLL
12151220
FreeLibrary (m_hInstDLL);
12161221
return CWinApp::ExitInstance();

dialogs/world_prefs/TreePropertySheet.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
#include "stdafx.h"
55
#include "TreePropertySheet.h"
6-
#include "themeglue.h"
76

87
#ifdef _DEBUG
98
#define new DEBUG_NEW
@@ -18,6 +17,9 @@ static char THIS_FILE[] = __FILE__;
1817
#define SPACEBOTTOM 15
1918
#define CAPTIONHEIGHT 20
2019

20+
HMODULE HModUXT = NULL;
21+
#include "themeglue.h"
22+
2123
/////////////////////////////////////////////////////////////////////////////
2224
// CTreePropertySheet
2325

dialogs/world_prefs/themeglue.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ extern "C" {
2222

2323
#include <windows.h>
2424

25-
HMODULE HModUXT = NULL;
26-
2725
#define THEMEGLUE_FUNC(FuncStr, params, result, FuncName, formal_params) \
2826
result FuncName formal_params \
2927
{ \
@@ -47,7 +45,6 @@ result FuncName formal_params \
4745

4846
THEMEGLUE_FUNC("EnableThemeDialogTexture", (hwnd, dwFlags), HRESULT, ThemeGlue_EnableThemeDialogTexture, (HWND hwnd, DWORD dwFlags))
4947

50-
5148
/* 2010-09-26: Yes, all this work for a single function. =)
5249
* But we might need more in the future, so I made it relatively easy to expand upon.
5350
* TODO: support for static linking against uxtheme.lib, but ideally we refactor

0 commit comments

Comments
 (0)