aboutsummaryrefslogtreecommitdiff
path: root/c/win.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'c/win.cpp')
-rw-r--r--c/win.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/c/win.cpp b/c/win.cpp
index e1349bc..40d68e4 100644
--- a/c/win.cpp
+++ b/c/win.cpp
@@ -4,6 +4,7 @@
#include <windows.h>
#include <wininet.h>
+#include "main.h"
#include "util.h"
#include "win.h"
@@ -86,9 +87,9 @@ static void CenterNextWindow(HWND hWnd)
int EBMessageBox(const std::wstring_view text, const std::wstring_view caption, const UINT uType)
{
- extern HWND g_hWnd;
- CenterNextWindow(g_hWnd);
- return MessageBox(g_hWnd, text.data(), caption.data(), uType);
+ extern Window* g_window;
+ CenterNextWindow(g_window->hWnd);
+ return MessageBox(g_window->hWnd, text.data(), caption.data(), uType);
}
void ShowException(const wchar_t* const fmt, const wchar_t* const title, const UINT uType) noexcept