Re: [Plib-devel] PUI questions
Brought to you by:
sjbaker
From: Steve B. <sjb...@ai...> - 2000-08-02 07:38:12
|
Dave McClurg wrote: > any thoughts on how to deal with deleting widgets inside a callback? > it seems so natural to get rid of widgets inside the callback when a > button is pressed. Yes - and you 'get away with it' in Linux - but under Windoze, it crashes. I'm a bit suprised at that. If the delete operator is the last function in the callback, the only code the compiler will generate afterwards should be a return instruction - what is there to crash?!? > i'll figure *something* out if there are no > approaches you already have in mind. Make a list of objects for deletion - and wipe them out at the end of the main PUI entrypoint. ppeDeleteMeLater ( this ) ; ...or something. > also, i'd like to add "const" in several places in the plib interfaces. > char* parameters often lack "const" where they should have it. > any thoughts about that? Sure - I'm just a bit lazy about that. I learned to program C/C++ *long* before 'const' was invented - and it's hard to shake old habits. -- Steve Baker HomeEmail: <sjb...@ai...> WorkEmail: <sj...@li...> HomePage : http://web2.airmail.net/sjbaker1 Projects : http://plib.sourceforge.net http://tuxaqfh.sourceforge.net http://tuxkart.sourceforge.net http://prettypoly.sourceforge.net |