Hi,

I have widget;

Qt Code:
  1. ...
  2.  
  3. MyWidget my_widget = new MyWidget(parentWidget/*this*/);
  4.  
  5. ...
To copy to clipboard, switch view to plain text mode 

when I delete the parent like;

Qt Code:
  1. delete parentWidget;
To copy to clipboard, switch view to plain text mode 

it deletes the child but it doesn't call the MyWidget's destructor right? If we want to call MyWidget's destructor, we need delete the child MyWidget explicitly like?


Qt Code:
  1. delete myWidget;
To copy to clipboard, switch view to plain text mode