Overdue change: handled WM_PRINTCLIENT in uiWindow.
This commit is contained in:
parent
317c4dbc22
commit
557ee68e47
|
@ -91,6 +91,8 @@ static INT_PTR CALLBACK dlgproc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPar
|
||||||
// unthemed dialogs don't respond to WM_PRINTCLIENT
|
// unthemed dialogs don't respond to WM_PRINTCLIENT
|
||||||
// fortunately they don't have any special painting
|
// fortunately they don't have any special painting
|
||||||
if (uMsg == WM_PRINTCLIENT) {
|
if (uMsg == WM_PRINTCLIENT) {
|
||||||
|
// don't worry about the return value; hopefully DefWindowProcW() caught it (if not the dialog procedure itself)
|
||||||
|
// we COULD paint the dialog background brush ourselves but meh, it works
|
||||||
SendMessageW(hwnd, WM_ERASEBKGND, wParam, lParam);
|
SendMessageW(hwnd, WM_ERASEBKGND, wParam, lParam);
|
||||||
// and pretend we did nothing just so the themed dialog can still paint its content
|
// and pretend we did nothing just so the themed dialog can still paint its content
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
|
@ -50,6 +50,11 @@ static LRESULT CALLBACK windowWndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARA
|
||||||
if (w->child != NULL)
|
if (w->child != NULL)
|
||||||
uiControlQueueResize(uiControl(w));
|
uiControlQueueResize(uiControl(w));
|
||||||
return 0;
|
return 0;
|
||||||
|
case WM_PRINTCLIENT:
|
||||||
|
// we do no special painting; just erase the background
|
||||||
|
// don't worry about the return value; we let DefWindowProcW() handle this message
|
||||||
|
SendMessageW(hwnd, WM_ERASEBKGND, wParam, lParam);
|
||||||
|
return 0;
|
||||||
case WM_CLOSE:
|
case WM_CLOSE:
|
||||||
if ((*(w->onClosing))(uiWindow(w), w->onClosingData))
|
if ((*(w->onClosing))(uiWindow(w), w->onClosingData))
|
||||||
uiControlDestroy(uiControl(w));
|
uiControlDestroy(uiControl(w));
|
||||||
|
|
Loading…
Reference in New Issue