Hi all, I have the following code and problem concerning the use of the GUI: I have a derived class from TGMainFrame (let's say class OTFrame1), which has all kinds of widgets. Pressing one of the buttons creates another TGMainFrame derived class (OTFrame2), which from then on should work 'stand alone' (i.e. in parallel) with the OTFrame1 frame, until it is deleted. The problem: I want the window maneger to be able to close OTFrame2 so I need to implement the member function CloseWindow(). Here I first call the CloseWindow member of the TGMainFrame base-class. But as far as I know this does not delete the OTFrame2 object. So how should I do that, and hwo do I inform the OTFrame1 object that the OTFrame2 object is deleted? I tried to do this by calling a member function of the OTFrame1 object which deletes it's pointer to the OTFrame2. But becuase this call is done from within the OTFrame2 CloseWindow member this (as to be expected) does not work proberly. (the object is deleted while the program is still executing it) Is there a way to solve this problem?
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:33 MET