11.6.8 Adding a WM_RBUTTONUP Case

You will need to use the BitBlt function to display the current bitmap. To do this, include the function in a WM_RBUTTONUP case in your window procedure, as follows:

case WM_RBUTTONUP:

    hdc = GetDC(hwnd);
    BitBlt(hdc, LOWORD(lParam), HIWORD(lParam),
        Bitmap.bmWidth, Bitmap.bmHeight,
        hdcMemory, 0, 0, SRCCOPY);
    ReleaseDC(hwnd, hdc);
    break;