diff --git a/include/MainWindow.hpp b/include/MainWindow.hpp index 6bf0110..d358e5b 100644 --- a/include/MainWindow.hpp +++ b/include/MainWindow.hpp @@ -18,6 +18,7 @@ protected: LRESULT OnCreate(); LRESULT OnDestroy(); void OnPaint(); + BOOL WinRegisterClass(WNDCLASS *pwc); virtual HICON GetIcon(); diff --git a/src/MainWindow.cpp b/src/MainWindow.cpp index 5119642..a09ac60 100644 --- a/src/MainWindow.cpp +++ b/src/MainWindow.cpp @@ -75,6 +75,12 @@ LRESULT APIENTRY EditSubclassProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lP wParam, lParam); } +BOOL MainWindow::WinRegisterClass(WNDCLASS *pwc) +{ + pwc->style = CS_HREDRAW | CS_VREDRAW; + return __super::WinRegisterClass(pwc); +} + LRESULT MainWindow::OnCreate() { NONCLIENTMETRICS ncmMetrics = { sizeof(NONCLIENTMETRICS) };