| 5 | #include "../../ProgramLog/error/std.hpp" |
| 6 | |
| 7 | void MessageWindow::init(Util::null_terminated_wstring_view windowName, DWORD style, DWORD extended_style, Window parent) |
| 8 | { |
| 9 | m_WindowHandle = Window::Create(extended_style, *m_WindowClass, windowName, style, 0, 0, 0, 0, parent); |
| 10 | if (!m_WindowHandle) |
| 11 | { |
| 12 | LastErrorHandle(spdlog::level::critical, L"Failed to create message window!"); |
| 13 | } |
| 14 | |
| 15 | const auto proc = m_ProcPage.make_thunk<WNDPROC>(this, &MessageWindow::MessageHandler); |
| 16 | m_ProcPage.mark_executable(); |
| 17 | |
| 18 | set_long_ptr<spdlog::level::critical>(GWLP_WNDPROC, reinterpret_cast<LONG_PTR>(proc)); |
| 19 | } |
| 20 | |
| 21 | MessageWindow::MessageWindow(WindowClass &classRef, Util::null_terminated_wstring_view windowName, DWORD style, DWORD extended_style, Window parent, const wchar_t *iconResource) : |
| 22 | m_WindowClass(&classRef, false), |
nothing calls this directly
no outgoing calls
no test coverage detected