Click here to Skip to main content
15,910,083 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Calculate the Array search time in millisecondes Pin
David Crow8-Jan-04 6:04
David Crow8-Jan-04 6:04 
QuestionIs this good form? Pin
Cloaca7-Jan-04 4:49
Cloaca7-Jan-04 4:49 
AnswerRe: Is this good form? Pin
Christian Graus7-Jan-04 10:05
protectorChristian Graus7-Jan-04 10:05 
GeneralRe: Is this good form? Pin
Cloaca7-Jan-04 11:53
Cloaca7-Jan-04 11:53 
AnswerRe: Is this good form? Pin
Mike Dimmick8-Jan-04 2:27
Mike Dimmick8-Jan-04 2:27 
GeneralRe: Is this good form? Pin
Cloaca8-Jan-04 5:02
Cloaca8-Jan-04 5:02 
GeneralRe: Is this good form? Pin
Mike Dimmick8-Jan-04 5:23
Mike Dimmick8-Jan-04 5:23 
GeneralRe: Is this good form? Pin
Cloaca8-Jan-04 11:33
Cloaca8-Jan-04 11:33 
Hi Mike,

Thanks again.
About reason 1.: Most times, the objects that are in a list are made using a call to 'new' at some point in the code. If this is the case, then the contents of the list (the newed objects) need to get deleted at some point anyway. And this must be done by walking through the list in a loop to call delete for each item before doing a RemoveAll() on the list.

Or, do you have a methodology in coding that 'recycles' objects. That is, a variable of type CMyObject is declared and reused (has its data changed) whenever an item needs to be added to the list. Then, due to storing actual T's (not T*'s or T&'s), they are passed by reference into the CList by value (so that the declared variable can be changed for reuse to create the next item in the list). Is this what you mean? Does this mean that the destructor for each item in the list is called when the CList is destroyed?

Thanks very much,
Eric
GeneralAdding text display to dialog box Pin
Anonymous7-Jan-04 4:36
Anonymous7-Jan-04 4:36 
GeneralRe: Adding text display to dialog box Pin
valikac7-Jan-04 7:28
valikac7-Jan-04 7:28 
GeneralHelp with HANDLEs Pin
Mortis7-Jan-04 4:14
Mortis7-Jan-04 4:14 
GeneralRe: Help with HANDLEs Pin
Dominik Reichl7-Jan-04 4:33
Dominik Reichl7-Jan-04 4:33 
GeneralRe: Help with HANDLEs Pin
valikac7-Jan-04 7:29
valikac7-Jan-04 7:29 
GeneralFucntion execution time Pin
islheg7-Jan-04 3:49
islheg7-Jan-04 3:49 
GeneralRe: Fucntion execution time Pin
фил7-Jan-04 4:30
фил7-Jan-04 4:30 
GeneralRe: Fucntion execution time Pin
oren frenkel7-Jan-04 6:27
oren frenkel7-Jan-04 6:27 
GeneralRe: Fucntion execution time Pin
Alexander M.,7-Jan-04 10:55
Alexander M.,7-Jan-04 10:55 
GeneralRe: Fucntion execution time Pin
pankajdaga8-Jan-04 3:57
pankajdaga8-Jan-04 3:57 
GeneralRe: Fucntion execution time Pin
islheg10-Jan-04 12:10
islheg10-Jan-04 12:10 
GeneralREMOVE AN ICON Pin
davrodriguez7-Jan-04 3:36
davrodriguez7-Jan-04 3:36 
GeneralRe: REMOVE AN ICON Pin
фил7-Jan-04 3:42
фил7-Jan-04 3:42 
GeneralRe: REMOVE AN ICON Pin
Dominik Reichl7-Jan-04 4:22
Dominik Reichl7-Jan-04 4:22 
GeneralJoystick/Gamepad input when window isn't active Pin
zhen857-Jan-04 3:26
zhen857-Jan-04 3:26 
GeneralRe: Joystick/Gamepad input when window isn't active Pin
zhen857-Jan-04 3:52
zhen857-Jan-04 3:52 
GeneralRe: Joystick/Gamepad input when window isn't active Pin
фил7-Jan-04 4:22
фил7-Jan-04 4:22 

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.