From f44c5c0a8883d265256ae943623dfc9680741f30 Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Tue, 31 Mar 2009 02:24:54 +0200 Subject: code fixing --- src/webview.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/webview.cpp b/src/webview.cpp index 7096d850..1057a5ef 100644 --- a/src/webview.cpp +++ b/src/webview.cpp @@ -85,6 +85,8 @@ bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &r return false; } + WebView *webView; + switch(type) { @@ -96,7 +98,7 @@ bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &r if(m_keyboardModifiers & Qt::ControlModifier || m_pressedButtons == Qt::MidButton) { kWarning() << "ControlModifiers clicked.."; - WebView *webView = Application::instance()->newWebView(); + webView = Application::instance()->newWebView(); webView->setFocus(); webView->load(request); m_keyboardModifiers = Qt::NoModifier; @@ -112,7 +114,7 @@ bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &r else { kWarning() << "NO Main Frame, creating a new WebView.."; - WebView *webView = Application::instance()->newWebView(); + webView = Application::instance()->newWebView(); webView->setFocus(); webView->load(request); return false; -- cgit v1.2.1