The problem of constant global refresh for plotting
Flyli2008-3-16
Today, I made a very low-level mistake. I made a map with buttons. The principle is to inherit a button class and draw a picture on the button surface, to avoid the flickering problem caused by global refresh (I didn't use dual cache), I used invalidatarect to perform partial refresh for some animation effects, to minimize the flickering area, I drew an image in the background. However, if you call invalidatarect to give a valid parameter, a global refresh will be generated, I have not found any problems for a long time, and I have been depressed for a long time...
Today, I finally found the problem. It was a very low-level problem. I didn't call the overwriting function at the upper level in OnEraseBkgnd (CDC * pDC...
So I added the return CDialog: OnEraseBkgnd (CDC * pDC) statement to get everything done ~~~~~