请问一个::InvalidateRect的问题?
对话框中一个IDC_PICTURE控件,两个button控件(button1 button2)
void CReaderDlg::Button1(){ HWND hpic=::GetDlgItem(m_hWnd,IDC_PICTURE); CWnd * pWnd = GetDlgItem(IDC_PICTURE); SetDIBitsToDevice(hdc, m_nPanx, m_nPany, m_pImage->w, m_pImage->h, 0, 0, 0, m_pImage->h, color, dibinf, DIB_RGB_COLORS); ::ReleaseDC(m_hWnd, hdc);}void CReaderDlg::Button2(){ HWND hpic=::GetDlgItem(m_hWnd,IDC_PICTURE); CWnd * pWnd = GetDlgItem(IDC_PICTURE); ::InvalidateRect(hpic, NULL, TRUE); ::ReleaseDC(m_hWnd, hdc); }