Click here to Skip to main content
15,914,016 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: dialog refresh Pin
Anonymous4-Feb-03 21:42
Anonymous4-Feb-03 21:42 
GeneralRe: dialog refresh Pin
Abbas_Riazi5-Feb-03 0:26
professionalAbbas_Riazi5-Feb-03 0:26 
GeneralRe: dialog refresh Pin
Anonymous4-Feb-03 21:41
Anonymous4-Feb-03 21:41 
GeneralMSDN annoying prompts Pin
ed welch4-Feb-03 5:14
ed welch4-Feb-03 5:14 
Generaldraw rectangle selection Pin
jeremysay4-Feb-03 5:10
jeremysay4-Feb-03 5:10 
GeneralRe: draw rectangle selection Pin
Michael Dunn4-Feb-03 5:18
sitebuilderMichael Dunn4-Feb-03 5:18 
GeneralRe: draw rectangle selection Pin
jeremysay4-Feb-03 5:51
jeremysay4-Feb-03 5:51 
GeneralMFC... WM_PAINT message Pin
Mciccarone3574-Feb-03 4:48
Mciccarone3574-Feb-03 4:48 
Hi Everybody,
I have a question concerning MFC and its paint message. I have been working on an OpenGL application that runs a Dialog Box, with various MFC controls and an OpenGL CFrameWnd running next to the controls. The program works great when the Program has focus, but, when the program is not active the CPU usage goes upto 100% by calling OnPaint repeatedly. I have the OpenGL rendering set to use the following three messages: ON_WM_ACTIVATEAPP(), ON_WM_NCACTIVATE(), ON_WM_ACTIVATE(). These trigger flags that disable the OpenGL rendering so I know that the graphical side is not an issue.

When I mimimize the program the Paint messages stop flooding in, but when the program is in the background the Paint messages pour in. Does anyone know how to prevent the WM_PAINT messages from being sent when the window, dialog, or program is not active?
GeneralRe: MFC... WM_PAINT message Pin
Roger Allen4-Feb-03 6:02
Roger Allen4-Feb-03 6:02 
GeneralRe: MFC... WM_PAINT message Pin
357magnum4-Feb-03 10:46
357magnum4-Feb-03 10:46 
GeneralRe: MFC... WM_PAINT message Pin
Paul M Watt4-Feb-03 20:42
mentorPaul M Watt4-Feb-03 20:42 
GeneralVisual C++ Pin
Rage4-Feb-03 4:45
professionalRage4-Feb-03 4:45 
Generalchange html help files to windows help files Pin
includeh104-Feb-03 4:25
includeh104-Feb-03 4:25 
GeneralRe: change html help files to windows help files Pin
Roger Allen4-Feb-03 6:06
Roger Allen4-Feb-03 6:06 
GeneralRe: change html help files to windows help files Pin
Iain Clarke, Warrior Programmer4-Feb-03 6:43
Iain Clarke, Warrior Programmer4-Feb-03 6:43 
GeneralMFC exe file size Pin
Anonymous4-Feb-03 4:13
Anonymous4-Feb-03 4:13 
GeneralRe: MFC exe file size Pin
RobJones4-Feb-03 4:36
RobJones4-Feb-03 4:36 
GeneralRe: MFC exe file size Pin
Anonymous4-Feb-03 4:50
Anonymous4-Feb-03 4:50 
GeneralRe: MFC exe file size Pin
Anonymous4-Feb-03 4:55
Anonymous4-Feb-03 4:55 
GeneralRe: MFC exe file size Pin
includeh104-Feb-03 5:40
includeh104-Feb-03 5:40 
GeneralRe: MFC exe file size Pin
Anonymous4-Feb-03 5:45
Anonymous4-Feb-03 5:45 
GeneralRe: MFC exe file size Pin
includeh104-Feb-03 6:55
includeh104-Feb-03 6:55 
GeneralRe: MFC exe file size Pin
Anonymous5-Feb-03 22:37
Anonymous5-Feb-03 22:37 
GeneralRe: MFC exe file size Pin
Nitron4-Feb-03 13:40
Nitron4-Feb-03 13:40 
GeneralRe: MFC exe file size Pin
Anonymous5-Feb-03 22:37
Anonymous5-Feb-03 22:37 

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.