Click here to Skip to main content
15,913,465 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: C++ question Pin
David Crow19-Nov-05 7:06
David Crow19-Nov-05 7:06 
GeneralRe: C++ question Pin
Owner drawn20-Nov-05 17:52
Owner drawn20-Nov-05 17:52 
GeneralRe: C++ question Pin
David Crow21-Nov-05 3:10
David Crow21-Nov-05 3:10 
AnswerRe: C++ question Pin
cmk18-Nov-05 2:19
cmk18-Nov-05 2:19 
QuestionDLL Function Noobie Pin
tadieckmann17-Nov-05 8:03
tadieckmann17-Nov-05 8:03 
AnswerRe: DLL Function Noobie Pin
kakan17-Nov-05 20:31
professionalkakan17-Nov-05 20:31 
Questionoddities of visual studio.net 2005.... Pin
(Steven Hicks)n+117-Nov-05 6:52
(Steven Hicks)n+117-Nov-05 6:52 
QuestionThreads in MFC - trying to understand... Pin
charlieg17-Nov-05 6:44
charlieg17-Nov-05 6:44 
I'm a veteren developer who is still trying to get his brain to absorb all of mfc before .net becomes obsolete Wink | ;) Anyway, I've read and studied John's excellent article, but there are some issues that make me go hmmm :



I understand WHY you don't do UI stuff in the worker threads, but I have a situation where I work that we seem to defy that logic. The application is a simple SDI which mainly uses its view to display dialog data. When the user presses the "make it so" button, a worker thread is launched that does all of the long work. Part of the information that is passed to this worker thread is a global to the view object. When the worker thread wishes to update the UI with status info, it simply:

pView->WhateverItNeedsToDo(arguments);

and the display is updated. Now, this just seems wrong to me.WTF | :WTF:

The view should be owned by the main application thread - a UI thread - accessing the object just seems like the end of the world should occur.

But it works. Is the application just lucky?



C. Gilley
Will program for food...
My son's PDA is an M249 SAW.

-- modified at 12:45 Thursday 17th November, 2005
AnswerRe: Threads in MFC - trying to understand... Pin
David Crow17-Nov-05 8:56
David Crow17-Nov-05 8:56 
GeneralRe: Threads in MFC - trying to understand... Pin
charlieg17-Nov-05 9:00
charlieg17-Nov-05 9:00 
AnswerRe: Threads in MFC - trying to understand... Pin
Sheng Jiang 蒋晟17-Nov-05 12:44
Sheng Jiang 蒋晟17-Nov-05 12:44 
GeneralRe: Threads in MFC - trying to understand... Pin
charlieg17-Nov-05 13:55
charlieg17-Nov-05 13:55 
GeneralRe: Threads in MFC - trying to understand... Pin
Sheng Jiang 蒋晟17-Nov-05 14:17
Sheng Jiang 蒋晟17-Nov-05 14:17 
QuestionThread Safe Static Library Problem Pin
Federico Milano17-Nov-05 2:38
Federico Milano17-Nov-05 2:38 
AnswerRe: Thread Safe Static Library Problem Pin
Graham Bradshaw17-Nov-05 2:48
Graham Bradshaw17-Nov-05 2:48 
GeneralRe: Thread Safe Static Library Problem Pin
Federico Milano17-Nov-05 4:17
Federico Milano17-Nov-05 4:17 
AnswerRe: Thread Safe Static Library Problem Pin
Tim Smith17-Nov-05 3:01
Tim Smith17-Nov-05 3:01 
AnswerRe: Thread Safe Static Library Problem Pin
James R. Twine17-Nov-05 6:09
James R. Twine17-Nov-05 6:09 
QuestionCHtmlView problem ? Pin
kendao17-Nov-05 2:34
kendao17-Nov-05 2:34 
AnswerRe: CHtmlView problem ? Pin
Sheng Jiang 蒋晟17-Nov-05 12:47
Sheng Jiang 蒋晟17-Nov-05 12:47 
QuestionCImageList question? Pin
followait17-Nov-05 0:39
followait17-Nov-05 0:39 
AnswerRe: CImageList question? Pin
Rage17-Nov-05 1:13
professionalRage17-Nov-05 1:13 
GeneralRe: CImageList question? Pin
followait17-Nov-05 3:18
followait17-Nov-05 3:18 
GeneralRe: CImageList question? Pin
Rage17-Nov-05 5:54
professionalRage17-Nov-05 5:54 
QuestionJavaScript from ActiveX Control Pin
Priyank Bolia17-Nov-05 0:30
Priyank Bolia17-Nov-05 0:30 

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.