add "this" when create Qt obiect.
[mdictionary] / trunk / src / base / gui / HistoryListDialog.cpp
index 97c5ce9..8905578 100644 (file)
 HistoryListDialog::HistoryListDialog(QStringList words, QWidget *parent):
         QDialog(parent)
 {
-    verticalLayout = new QVBoxLayout;
+    verticalLayout = new QVBoxLayout(this);
     setLayout(verticalLayout);
 
     oryginalList = words;
 
-    historyListWidget = new QListWidget;
+    historyListWidget = new QListWidget(this);
     verticalLayout->addWidget(historyListWidget);
 
     for(int i=0; i<words.count(); i++) {