[wxPython] EVT_CLOSE vs EVT_DESTROY

i use a derived class from wxTextCtrl.(class CIpText(wxTextCtrl):slight_smile:

within the construction i create a second control (a button) as

neighbour of the wxTextCtrl.

class CIPText(wx.wxTextCtrl):

...

def __init__(....):

    ...

    #create the neighbour
    self.toggle = wxGenToggleButton(parent, -1, "IP", (_wxPos.x, _wxPos.y), _wxSize)

Problem:

whats the best way to delete the neighbour control when the CIPText control destroys ?

i tried to overload Destroy. but on Linux the system crashes …

thanks…

···

===========================================================
Heinl Raimund SSH - Software Systeme Heinl
gepr.Wirtschaftsinformatiker IHK Am Galling 3
Tel. 09151 / 7 10 99 91217 Hersbruck
Fax. 09151 / 90 50 51
http: coming soon
Email: heinlr@gmx.de

whats the best way to delete the neighbour control when the
CIPText control destroys ? i tried to overload Destroy. but
on Linux the system crashes ...

Normally you don't have to worry about it as both will be destroyed when the
parent is.

···

--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters?
http://wxPython.org Relax with wxPython!