diff options
author | megabigbug <megabigbug@arrakis.(none)> | 2009-12-17 16:49:15 +0100 |
---|---|---|
committer | megabigbug <megabigbug@arrakis.(none)> | 2009-12-17 16:49:15 +0100 |
commit | a0245069cf175d4657913e4cbf2898fe4e31281f (patch) | |
tree | bb52cd481d4678764590cf5824913eb7420e93bf /src | |
parent | not sure about this.. (diff) | |
download | rekonq-a0245069cf175d4657913e4cbf2898fe4e31281f.tar.xz |
fix crashes webtabs
Diffstat (limited to 'src')
-rw-r--r-- | src/mainview.cpp | 4 | ||||
-rw-r--r-- | src/webtab.cpp | 3 | ||||
-rw-r--r-- | src/webview.cpp | 1 |
3 files changed, 5 insertions, 3 deletions
diff --git a/src/mainview.cpp b/src/mainview.cpp index 8e0a6eb4..f614df2a 100644 --- a/src/mainview.cpp +++ b/src/mainview.cpp @@ -481,10 +481,10 @@ void MainView::closeTab(int index) } } - QWidget *webView = this->webTab(index); + QWidget *webTab = this->webTab(index); removeTab(index); updateTabBar(); // UI operation: do it ASAP!! - webView->deleteLater(); // webView is scheduled for deletion. + delete webTab; // webView is scheduled for deletion. emit tabsChanged(); diff --git a/src/webtab.cpp b/src/webtab.cpp index a39abaf2..80c43c78 100644 --- a/src/webtab.cpp +++ b/src/webtab.cpp @@ -61,7 +61,7 @@ WebTab::WebTab(QWidget* parent) : QWidget(parent) - , m_view( new WebView(parent) ) + , m_view( new WebView(this) ) , m_progress(0) { QVBoxLayout* l = new QVBoxLayout(this); @@ -98,6 +98,7 @@ WebTab::WebTab(QWidget* parent) WebTab::~WebTab() { + delete m_view; } diff --git a/src/webview.cpp b/src/webview.cpp index 0ba04bc2..0b589ec0 100644 --- a/src/webview.cpp +++ b/src/webview.cpp @@ -71,6 +71,7 @@ WebView::WebView(QWidget* parent) WebView::~WebView() { + disconnect(); } |