From c2b2f0157103c147d4c30a79658f3096e9b68bf1 Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Thu, 11 Dec 2008 11:02:07 +0100 Subject: ctrl + click open new tab AND select --- src/tabwidget.cpp | 1 - src/webview.cpp | 6 ++---- src/webview.h | 1 + 3 files changed, 3 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/tabwidget.cpp b/src/tabwidget.cpp index 58ea75c0..0b815b6e 100644 --- a/src/tabwidget.cpp +++ b/src/tabwidget.cpp @@ -639,7 +639,6 @@ void TabWidget::webViewLoadStarted() int index = webViewIndex(webView); if (-1 != index) { -// QIcon icon(QLatin1String(":loading.gif")); setTabIcon(index, KIcon("rekonq") ); } } diff --git a/src/webview.cpp b/src/webview.cpp index b14b4936..b03c9291 100644 --- a/src/webview.cpp +++ b/src/webview.cpp @@ -63,8 +63,7 @@ BrowserMainWindow *WebPage::mainWindow() bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &request, NavigationType type) { - // ctrl open in new tab - // ctrl-shift open in new tab and select + // ctrl open in new tab and select // ctrl-alt open in new window if ( type == QWebPage::NavigationTypeLinkClicked && (m_keyboardModifiers & Qt::ControlModifier || m_pressedButtons == Qt::MidButton) ) @@ -82,8 +81,7 @@ bool WebPage::acceptNavigationRequest(QWebFrame *frame, const QNetworkRequest &r } else { - bool selectNewTab = (m_keyboardModifiers & Qt::ShiftModifier); - webView = mainWindow()->tabWidget()->newTab(selectNewTab); + webView = mainWindow()->tabWidget()->newTab( true ); } webView->load(request); m_keyboardModifiers = Qt::NoModifier; diff --git a/src/webview.h b/src/webview.h index b2e97efb..62d4f3a5 100644 --- a/src/webview.h +++ b/src/webview.h @@ -67,6 +67,7 @@ private: // --------------------------------------------------------------------------------------------------------------------------------------- + class WebView : public QWebView { Q_OBJECT -- cgit v1.2.1