Click here to Skip to main content
15,895,667 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralResources .rc question Pin
Braulio Dez20-Nov-02 0:26
Braulio Dez20-Nov-02 0:26 
GeneralRe: Resources .rc question Pin
RuiSantiago20-Nov-02 0:43
RuiSantiago20-Nov-02 0:43 
GeneralRe: Resources .rc question Pin
georgiek5020-Nov-02 1:41
georgiek5020-Nov-02 1:41 
GeneralRe: Resources .rc question Pin
Braulio Dez20-Nov-02 2:28
Braulio Dez20-Nov-02 2:28 
GeneralRe: Resources .rc question Pin
Braulio Dez21-Nov-02 1:08
Braulio Dez21-Nov-02 1:08 
GeneralRe: Resources .rc question Pin
georgiek5021-Nov-02 2:47
georgiek5021-Nov-02 2:47 
GeneralRe: Resources .rc question Pin
Braulio Dez21-Nov-02 2:56
Braulio Dez21-Nov-02 2:56 
Generalpainting background while resizing..... Pin
Neha19-Nov-02 23:58
Neha19-Nov-02 23:58 
Hi,
I have written this code to paint the background while resizing.
BOOL FrameWnd::OnEraseBkgnd(CDC* pDC)
{
CRect the_clientRect;
GetClientRect(&the_clientRect);
BITMAP the_bmp;
GetObject(the_bkgnd,sizeof(the_bmp),&the_bmp);
HDC hMemdc=CreateCompatibleDC(pDC->m_hDC);
if(hMemdc)
{
HBITMAP hOldBmp=(HBITMAP)SelectObject(hMemdc,the_bkgnd);
if(hOldBmp)
{
StretchBlt(pDC->m_hDC,0,0,the_clientRect.Width(),the_clientRect.Height(),hMemdc,0,0,the_bmp.bmWidth,the_bmp.bmHeight,SRCCOPY);
SelectObject(hMemdc,hOldBmp);
DeleteDC(hMemdc);
DeleteObject(hOldBmp);
return TRUE;
}
else
DeleteDC(hMemdc);
}
return TRue;
}

It works fine.But it flickers a lot.
Is there anyway to stop this flickering?

Regards,
Neha




GeneralRe: painting background while resizing..... Pin
Rickard Andersson2020-Nov-02 1:23
Rickard Andersson2020-Nov-02 1:23 
GeneralRe: painting background while resizing..... Pin
Gary R. Wheeler20-Nov-02 13:57
Gary R. Wheeler20-Nov-02 13:57 
GeneralRe: painting background while resizing..... Pin
Anonymous20-Nov-02 20:39
Anonymous20-Nov-02 20:39 
GeneralRe: painting background while resizing..... Pin
KarstenK20-Nov-02 1:24
mveKarstenK20-Nov-02 1:24 
GeneralRe: painting background while resizing..... Pin
georgiek5020-Nov-02 2:21
georgiek5020-Nov-02 2:21 
GeneralRe: painting background while resizing..... Pin
KarstenK20-Nov-02 2:41
mveKarstenK20-Nov-02 2:41 
GeneralRe: painting background while resizing..... Pin
georgiek5020-Nov-02 8:38
georgiek5020-Nov-02 8:38 
GeneralWH_JOURNALRECORD and WH_JOURNALPLAYBACK Pin
w200219-Nov-02 23:53
w200219-Nov-02 23:53 
GeneralCWebBrowser2 Control Question Pin
Anonymous19-Nov-02 23:49
Anonymous19-Nov-02 23:49 
GeneralRe: CWebBrowser2 Control Question Pin
Shaun Wilde20-Nov-02 1:22
Shaun Wilde20-Nov-02 1:22 
GeneralRe: CWebBrowser2 Control Question Pin
Anonymous22-Nov-02 2:44
Anonymous22-Nov-02 2:44 
GeneralRe: CWebBrowser2 Control Question Pin
Shaun Wilde22-Nov-02 5:25
Shaun Wilde22-Nov-02 5:25 
General::Postmessage(...) Pin
Raphael Kindt19-Nov-02 23:43
Raphael Kindt19-Nov-02 23:43 
GeneralRe: ::Postmessage(...) Pin
Hans Ruck20-Nov-02 1:03
Hans Ruck20-Nov-02 1:03 
GeneralIn what situation the winsock overlapped operation will return without complete the task Pin
Kerry Chou19-Nov-02 23:31
Kerry Chou19-Nov-02 23:31 
GeneralRe: In what situation the winsock overlapped operation will return without complete the task Pin
Jon Hulatt20-Nov-02 1:43
Jon Hulatt20-Nov-02 1:43 
QuestionHow to Get LPDRAWITEMSTRUCT from CWnd pointer? Pin
RuiSantiago19-Nov-02 23:31
RuiSantiago19-Nov-02 23:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.